thingspeak/app/models/user_session.rb
2011-03-27 16:56:15 -04:00

7 lines
176 B
Ruby

class UserSession < Authlogic::Session::Base
find_by_login_method :find_by_login_or_email
def to_key
new_record? ? nil : [ self.send(self.class.primary_key) ]
end
end