Class: MakeEmailNullable

Inherits:
ActiveRecord::Migration
  • Object
show all
Defined in:
lib/generators/happy_seed/omniauth/templates/make_email_nullable.rb

Instance Method Summary collapse

Instance Method Details

#changeObject



2
3
4
5
6
# File 'lib/generators/happy_seed/omniauth/templates/make_email_nullable.rb', line 2

def change
  change_column_null :users, :email, true
  remove_index :users, :email
  add_index :users, :email
end