Class: HasSecurePasskey::AddPasskey
- Inherits:
-
Object
- Object
- HasSecurePasskey::AddPasskey
- Defined in:
- lib/has_secure_passkey/add_passkey.rb
Instance Method Summary collapse
-
#initialize(authenticatable:, params:) ⇒ AddPasskey
constructor
A new instance of AddPasskey.
- #save ⇒ Object
Constructor Details
#initialize(authenticatable:, params:) ⇒ AddPasskey
Returns a new instance of AddPasskey.
2 3 4 5 |
# File 'lib/has_secure_passkey/add_passkey.rb', line 2 def initialize(authenticatable:, params:) @authenticatable = authenticatable @params = params end |
Instance Method Details
#save ⇒ Object
7 8 9 10 11 12 13 14 |
# File 'lib/has_secure_passkey/add_passkey.rb', line 7 def save if valid? passkey.save passkey else false end end |