RailsCasts Pro episodes are now free!
Learn more or hide this
GitHub User: mgmacri
def self.authenticate(email, password) find_by_email(email).try(:authenticate, password) end
Upon login I get the following error returned:
NoMethodError in SessionsController#create
undefined method `authenticate' for #Class:0xb69d4638
class User < ActiveRecord::Base has_secure_password attr_accessible :email, :password_digest, :password, :password_confirmation validates_uniqueness_of :email end
Any suggestions?
Upon login I get the following error returned:
NoMethodError in SessionsController#create
undefined method `authenticate' for #Class:0xb69d4638
Any suggestions?