diff options
author | Timothy Andrew <mail@timothyandrew.net> | 2016-09-20 14:01:52 +0300 |
---|---|---|
committer | Timothy Andrew <mail@timothyandrew.net> | 2016-09-20 14:01:52 +0300 |
commit | 8747f29db7d5f00ff48972097573f722d6b71627 (patch) | |
tree | 69de3c379f5befeb7b1d83ad5da286838c8f97f3 /db/migrate/20160825052008_add_table_merge_request_metrics.rb | |
parent | 9691d7e226da7bb468b3dc5ad410d21f8df4c243 (diff) |
Fix `ON DELETE CASCADE` migrations.
Incorrect syntax.
Diffstat (limited to 'db/migrate/20160825052008_add_table_merge_request_metrics.rb')
-rw-r--r-- | db/migrate/20160825052008_add_table_merge_request_metrics.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/db/migrate/20160825052008_add_table_merge_request_metrics.rb b/db/migrate/20160825052008_add_table_merge_request_metrics.rb index d743134d9a2..bde9238b3c6 100644 --- a/db/migrate/20160825052008_add_table_merge_request_metrics.rb +++ b/db/migrate/20160825052008_add_table_merge_request_metrics.rb @@ -25,7 +25,7 @@ class AddTableMergeRequestMetrics < ActiveRecord::Migration def change create_table :merge_request_metrics do |t| - t.references :merge_request, index: { name: "index_merge_request_metrics" }, foreign_key: true, dependent: :delete, null: false + t.references :merge_request, index: { name: "index_merge_request_metrics" }, foreign_key: { on_delete: :cascade }, null: false t.datetime 'latest_build_started_at' t.datetime 'latest_build_finished_at' |