Module: Sorcery::Model::Submodules::UserActivation::ClassMethods
- Defined in:
- lib/sorcery/model/submodules/user_activation.rb
Instance Method Summary collapse
-
#load_from_activation_token(token) ⇒ Object
Find user by token, also checks for expiration.
Instance Method Details
#load_from_activation_token(token) ⇒ Object
Find user by token, also checks for expiration. Returns the user if token found and is valid.
73 74 75 76 77 |
# File 'lib/sorcery/model/submodules/user_activation.rb', line 73 def load_from_activation_token(token) token_attr_name = @sorcery_config.activation_token_attribute_name token_expiration_date_attr = @sorcery_config.activation_token_expires_at_attribute_name load_from_token(token, token_attr_name, token_expiration_date_attr) end |