Here's my user model:
class User < ActiveRecord::Base
devise :database_authenticatable, :registerable,
:recoverable, :rememberable, :trackable, :validatable,:confirmable
# Setup accessible (or protected) attributes for your model
attr_accessible :email, :password, :password_confirmation, :remember_me
end
Here's the schema.rb:
create_table "users", :force => true do |t|
t.string "email", :default => "", :null => false
t.string "encrypted_password", :default => "", :null => false
t.string "reset_password_token"
t.datetime "reset_password_sent_at"
t.datetime "remember_created_at"
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"
t.string "confirmation_token"
t.datetime "confirmed_at"
t.datetime "confirmation_sent_at"
t.datetime "created_at", :null => false
t.datetime "updated_at", :null => false
t.integer "profile_id"
t.string "profile_type"
end
And in my initializer, devise.rb, I set this:
config.reconfirmable = false
I receive a mail telling me to click on confirm my account, and when I do, I get this error:
NameError in Devise::ConfirmationsController#show
undefined local variable or method `unconfirmed_email' for #<User:0xaa53818>
How can I fix it?
It was not a problem with Devise, but with me not restarting the development server.