diff options
Diffstat (limited to 'db/migrate/20171122120436_add_index_account_and_reblog_of_id_to_statuses.rb')
-rw-r--r-- | db/migrate/20171122120436_add_index_account_and_reblog_of_id_to_statuses.rb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/db/migrate/20171122120436_add_index_account_and_reblog_of_id_to_statuses.rb b/db/migrate/20171122120436_add_index_account_and_reblog_of_id_to_statuses.rb new file mode 100644 index 000000000..131e54b72 --- /dev/null +++ b/db/migrate/20171122120436_add_index_account_and_reblog_of_id_to_statuses.rb @@ -0,0 +1,12 @@ +class AddIndexAccountAndReblogOfIdToStatuses < ActiveRecord::Migration[5.1] + disable_ddl_transaction! + + def up + # This index has been superseded by migration 20171125185353 + # add_index :statuses, [:account_id, :reblog_of_id], algorithm: :concurrently + end + + def down + remove_index :statuses, [:account_id, :reblog_of_id] if index_exists?(:statuses, [:account_id, :reblog_of_id]) + end +end |