Module: Sorcery::Model::Submodules::ResetPassword::ClassMethods
- Defined in:
- lib/sorcery/model/submodules/reset_password.rb
Instance Method Summary collapse
-
#load_from_reset_password_token(token) ⇒ Object
Find user by token, also checks for expiration.
Instance Method Details
#load_from_reset_password_token(token) ⇒ Object
Find user by token, also checks for expiration. Returns the user if token found and is valid.
56 57 58 59 60 |
# File 'lib/sorcery/model/submodules/reset_password.rb', line 56 def load_from_reset_password_token(token) token_attr_name = @sorcery_config.reset_password_token_attribute_name token_expiration_date_attr = @sorcery_config.reset_password_token_expires_at_attribute_name load_from_token(token, token_attr_name, token_expiration_date_attr) end |