BigW Consortium Gitlab

20160920160832_add_index_to_labels_title.rb 322 Bytes
Newer Older
1
# rubocop:disable RemoveIndex
2 3 4 5 6 7 8
class AddIndexToLabelsTitle < ActiveRecord::Migration
  include Gitlab::Database::MigrationHelpers

  DOWNTIME = false

  disable_ddl_transaction!

9
  def up
10 11
    add_concurrent_index :labels, :title
  end
12 13 14 15

  def down
    remove_index :labels, :title if index_exists? :labels, :title
  end
16
end