mirror of
https://github.com/dani-garcia/vaultwarden.wiki.git
synced 2026-10-23 10:18:09 +03:00
automatically use email address as 2fa provider (#4317)
This commit is contained in:
1 parent
7c3cad197c
commit
79ce5b49bc
7 files changed
+90
-12
No files matched your search
@@ -340,4 +340,11 @@ impl OrgPolicy {
|
||||
}
|
||||
false
|
||||
}
|
||||
|
||||
pub async fn is_enabled_by_org(org_uuid: &str, policy_type: OrgPolicyType, conn: &mut DbConn) -> bool {
|
||||
if let Some(policy) = OrgPolicy::find_by_org_and_type(org_uuid, policy_type, conn).await {
|
||||
return policy.enabled;
|
||||
}
|
||||
false
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user