Class: Booth::Models::Credential
Instance Method Summary
collapse
#authenticate_otp, #otp_provisioning_svg, #otp_provisioning_url
#allows_mode_username_and_password?, #allows_mode_username_and_webauth?, #allows_mode_username_password_and_otp?, #allows_mode_username_password_and_webauth?, #requires_user_verification?
Instance Method Details
#applicable_for_password_reset? ⇒ Boolean
Also known as:
passworded?
33
34
35
36
37
|
# File 'lib/booth/models/credential.rb', line 33
def applicable_for_password_reset?
mode_username_and_password? ||
mode_username_password_and_otp? ||
mode_username_password_and_webauth?
end
|
#registered_authenticator_ids ⇒ Object
40
41
42
43
44
|
# File 'lib/booth/models/credential.rb', line 40
def registered_authenticator_ids
authenticators.registered_scope
.sorted_scope
.pluck(:device_id)
end
|
#remote_session_available? ⇒ Boolean
29
30
31
|
# File 'lib/booth/models/credential.rb', line 29
def remote_session_available?
sessions.active_scope.any?
end
|