Commit 408326e0 authored by Harrison Brock's avatar Harrison Brock Committed by Marcel Amirault

Adding variable INDEX_NAME to keep all code examples the same in the docs.

parent 4ca69686
......@@ -516,12 +516,14 @@ class MyMigration < ActiveRecord::Migration[6.0]
disable_ddl_transaction!
INDEX_NAME = 'index_name'
def up
add_concurrent_index :table, :column
add_concurrent_index :table, :column, name: INDEX_NAME
end
def down
remove_concurrent_index :table, :column, name: index_name
remove_concurrent_index :table, :column, name: INDEX_NAME
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