mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-05-02 05:06:51 +08:00
13 lines
371 B
Ruby
13 lines
371 B
Ruby
# frozen_string_literal: true
|
|
|
|
class RemoveUniqueConstraintFromInvitesIndex < ActiveRecord::Migration[4.2]
|
|
def up
|
|
remove_index :invites, %i[email invited_by_id]
|
|
add_index :invites, %i[email invited_by_id], unique: false
|
|
end
|
|
|
|
def down
|
|
remove_index :invites, %i[email invited_by_id]
|
|
add_index :invites, %i[email invited_by_id], unique: true
|
|
end
|
|
end
|