Fix old migrations failing because of new version of `strong_migrations` (#10904)
parent
acc74bed12
commit
1c78d600d3
@ -1,5 +1,5 @@
|
|||||||
class AddForeignKeyToAccountModerationNotes < ActiveRecord::Migration[5.1]
|
class AddForeignKeyToAccountModerationNotes < ActiveRecord::Migration[5.1]
|
||||||
def change
|
def change
|
||||||
add_foreign_key :account_moderation_notes, :accounts
|
safety_assured { add_foreign_key :account_moderation_notes, :accounts }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
class AddMovedToAccountIdToAccounts < ActiveRecord::Migration[5.1]
|
class AddMovedToAccountIdToAccounts < ActiveRecord::Migration[5.1]
|
||||||
def change
|
def change
|
||||||
add_column :accounts, :moved_to_account_id, :bigint, null: true, default: nil
|
add_column :accounts, :moved_to_account_id, :bigint, null: true, default: nil
|
||||||
add_foreign_key :accounts, :accounts, column: :moved_to_account_id, on_delete: :nullify
|
safety_assured { add_foreign_key :accounts, :accounts, column: :moved_to_account_id, on_delete: :nullify }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in new issue