mirror of
https://github.com/mastodon/mastodon.git
synced 2024-08-20 21:08:15 -07:00
11 lines
371 B
Ruby
11 lines
371 B
Ruby
class OptimizeIndexSubscriptions < ActiveRecord::Migration[5.0]
|
|
def up
|
|
add_index :subscriptions, [:account_id, :callback_url], unique: true
|
|
remove_index :subscriptions, [:callback_url, :account_id]
|
|
end
|
|
|
|
def down
|
|
add_index :subscriptions, [:callback_url, :account_id], unique: true
|
|
remove_index :subscriptions, [:account_id, :callback_url]
|
|
end
|
|
end
|