Module: Outpost::Model::Authentication::ClassMethods

Defined in:
lib/outpost/model/authentication.rb

Instance Method Summary collapse

Instance Method Details

#authenticate(login, unencrypted_password) ⇒ Object



18
19
20
21
22
23
24
25
# File 'lib/outpost/model/authentication.rb', line 18

def authenticate(, unencrypted_password)
  if user = self.send(
  "find_by_#{Outpost.config.authentication_attribute}", )
    user.authenticate(unencrypted_password)
  else
    false
  end
end