Ignore error in upgrade to allow Postgres 12 to work. Fixes #133

This commit is contained in:
Tulir Asokan 2020-04-02 21:11:38 +03:00
parent 78d3d22cd4
commit 9b01166f0c

View file

@ -12,7 +12,7 @@ func init() {
}
_, err := tx.Exec("ALTER TABLE message DROP CONSTRAINT message_chat_jid_fkey")
if err != nil {
return err
return nil
}
_, err = tx.Exec(`ALTER TABLE message ADD CONSTRAINT message_chat_jid_fkey
FOREIGN KEY (chat_jid, chat_receiver) REFERENCES portal(jid, receiver)