Module: AuthlogicCrowd::Session::InstanceMethods
- Defined in:
- lib/authlogic_crowd/session.rb
Instance Method Summary collapse
- #auto_register? ⇒ Boolean
- #crowd_client ⇒ Object
- #crowd_record ⇒ Object
- #crowd_synchronizer ⇒ Object
- #initialize(*args) ⇒ Object
-
#new_registration? ⇒ Boolean
Determines if the authenticated user is also a new registration.
Instance Method Details
#auto_register? ⇒ Boolean
58 59 60 |
# File 'lib/authlogic_crowd/session.rb', line 58 def auto_register? self.class.auto_register_value end |
#crowd_client ⇒ Object
70 71 72 |
# File 'lib/authlogic_crowd/session.rb', line 70 def crowd_client @crowd_client ||= klass.crowd_client end |
#crowd_record ⇒ Object
62 63 64 65 66 67 68 |
# File 'lib/authlogic_crowd/session.rb', line 62 def crowd_record if @valid_crowd_user[:user_token] && !@valid_crowd_user.has_key?(:record) @valid_crowd_user[:record] = crowd_client.find_user_by_token(@valid_crowd_user[:user_token]) end @valid_crowd_user[:record] end |
#crowd_synchronizer ⇒ Object
74 75 76 |
# File 'lib/authlogic_crowd/session.rb', line 74 def crowd_synchronizer @crowd_synchronizer ||= klass.crowd_synchronizer(crowd_client) end |
#initialize(*args) ⇒ Object
47 48 49 50 |
# File 'lib/authlogic_crowd/session.rb', line 47 def initialize(*args) super @valid_crowd_user = {} end |
#new_registration? ⇒ Boolean
Determines if the authenticated user is also a new registration. For use in the session controller to help direct the most appropriate action to follow.
54 55 56 |
# File 'lib/authlogic_crowd/session.rb', line 54 def new_registration? new_registration || !new_registration.nil? end |