summaryrefslogtreecommitdiff
path: root/db/migrate/20170531202042_rename_users_ldap_email_to_external_email.rb
blob: 7b1a76445553515f289be98bec5912cfe54beeeb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
class RenameUsersLdapEmailToExternalEmail < ActiveRecord::Migration[4.2]
  include Gitlab::Database::MigrationHelpers

  DOWNTIME = false

  disable_ddl_transaction!

  def up
    # rubocop:disable Migration/UpdateLargeTable
    rename_column_concurrently :users, :ldap_email, :external_email
  end

  def down
    cleanup_concurrent_column_rename :users, :external_email, :ldap_email
  end
end