summaryrefslogtreecommitdiffstats
path: root/db/migrate/20221012135202_add_index_to_custom_values.rb
blob: 21f5670aa0f13a8834cb78b91aac1ae2b16d3439 (plain)
1
2
3
4
5
6
class AddIndexToCustomValues < ActiveRecord::Migration[6.1]
  def change
    remove_index :custom_values, column: [:customized_type, :customized_id], name: :custom_values_customized, if_exists: true
    add_index :custom_values, [:customized_type, :customized_id, :custom_field_id], name: :custom_values_customized_custom_field
  end
end