Commit ee97c1ac authored by Krasimir Angelov's avatar Krasimir Angelov

Update docs to disable rule in DB guides example

In the example for "Creating a new table when we have two foreign keys"
we recommend using `add_foreign_key` but we have a Rubocop rule that
warns against its usage - Migration/AddConcurrentForeignKey.

This updates the examples too disable this rule.
parent 0e9ed172
......@@ -300,7 +300,7 @@ include Gitlab::Database::MigrationHelpers
def up
with_lock_retries do
add_foreign_key :imports, :projects, column: :project_id, on_delete: :cascade
add_foreign_key :imports, :projects, column: :project_id, on_delete: :cascade # rubocop:disable Migration/AddConcurrentForeignKey
end
end
......@@ -318,7 +318,7 @@ include Gitlab::Database::MigrationHelpers
def up
with_lock_retries do
add_foreign_key :imports, :users, column: :user_id, on_delete: :cascade
add_foreign_key :imports, :users, column: :user_id, on_delete: :cascade # rubocop:disable Migration/AddConcurrentForeignKey
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment