Follow up for issue #1977 - recent_views fk already exists, reconnect on postgres to be able to execute further sql statements.
This commit is contained in:
parent
b764e7b3e5
commit
9379d7afe6
1 changed files with 1 additions and 0 deletions
|
@ -29,6 +29,7 @@ class Issue1977RemoveInvalidUserForeignKeys < ActiveRecord::Migration[5.1]
|
||||||
rescue ActiveRecord::StatementInvalid => e
|
rescue ActiveRecord::StatementInvalid => e
|
||||||
Rails.logger.info "Can't add foreign_keys '#{args.inspect}'"
|
Rails.logger.info "Can't add foreign_keys '#{args.inspect}'"
|
||||||
Rails.logger.info e
|
Rails.logger.info e
|
||||||
|
ActiveRecord::Base.connection.reconnect!
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue