mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2025-11-25 20:16:18 -05:00
make webauthn more optional (#6160)
* make webauthn optional * hide passkey if domain is not set
This commit is contained in:
@@ -1525,6 +1525,10 @@ impl Config {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn is_webauthn_2fa_supported(&self) -> bool {
|
||||
Url::parse(&self.domain()).expect("DOMAIN not a valid URL").domain().is_some()
|
||||
}
|
||||
|
||||
/// Tests whether the admin token is set to a non-empty value.
|
||||
pub fn is_admin_token_set(&self) -> bool {
|
||||
let token = self.admin_token();
|
||||
|
||||
Reference in New Issue
Block a user