Class: NoPassword::Email::Authentication
- Inherits:
-
Session::Authentication
- Object
- Session::Authentication
- NoPassword::Email::Authentication
- Defined in:
- lib/nopassword/email/authentication.rb
Overview
Email-specific authentication that adds email validation and normalization.
Instance Method Summary collapse
-
#email=(value) ⇒ Object
Normalize email on assignment.
-
#identifier ⇒ Object
Email is the identifier for this authentication type.
Methods inherited from Session::Authentication
#challenge, #delete, #initialize, #persisted?, #save, #save!, #save_without_validation, update, #verification
Constructor Details
This class inherits a constructor from NoPassword::Session::Authentication
Instance Method Details
#email=(value) ⇒ Object
Normalize email on assignment
10 11 12 |
# File 'lib/nopassword/email/authentication.rb', line 10 def email=(value) super(value&.strip&.downcase) end |
#identifier ⇒ Object
Email is the identifier for this authentication type
15 16 17 |
# File 'lib/nopassword/email/authentication.rb', line 15 def identifier email end |