Sha256: 7122b8b91f7abbe7a24572f175f0913027df40323a42edba292e836d02930291

Contents?: true

Size: 1015 Bytes

Versions: 5

Compression:

Stored size: 1015 Bytes

Contents

# This migration comes from beerify (originally 20130805212414)
class AddDeviseToUsers < ActiveRecord::Migration
  def self.up
    change_table(:users) do |t|
      ## Database authenticatable
      t.string :email,              null: false, default: ""
      t.string :encrypted_password, null: false, default: ""

      ## Recoverable
      t.string   :reset_password_token
      t.datetime :reset_password_sent_at

      ## Rememberable
      t.datetime :remember_created_at

      ## Trackable
      t.integer  :sign_in_count, default: 0
      t.datetime :current_sign_in_at
      t.datetime :last_sign_in_at
      t.string   :current_sign_in_ip
      t.string   :last_sign_in_ip

      ## Token authenticatable
      t.string :authentication_token
    end

    add_index :users, :email,                unique: true
    add_index :users, :reset_password_token, unique: true
    add_index :users, :authentication_token, unique: true
  end

  def self.down
    raise ActiveRecord::IrreversibleMigration
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
beerify-0.2.0 spec/dummy/db/migrate/20131009094349_add_devise_to_users.beerify.rb
beerify-0.1.3 spec/dummy/db/migrate/20131009094349_add_devise_to_users.beerify.rb
beerify-0.1.2 spec/dummy/db/migrate/20131009094349_add_devise_to_users.beerify.rb
beerify-0.1.1 spec/dummy/db/migrate/20130904085930_add_devise_to_users.beerify.rb
beerify-0.1.0 spec/dummy/db/migrate/20130904085930_add_devise_to_users.beerify.rb