mirror of
https://github.com/dani-garcia/vaultwarden.wiki.git
synced 2026-11-04 14:46:47 +02:00
Clippy fixes, crate and web-vault updates (#7920)
This commit is contained in:
1 parent
79ee29d501
commit
5d870b796f
7 files changed
+512
-175
No files matched your search
@@ -2907,12 +2907,11 @@ async fn recover_account(
|
||||
err!("Organization user must be confirmed for password reset functionality");
|
||||
}
|
||||
|
||||
let fallback_2fa_email =
|
||||
if req.reset_two_factor && CONFIG.mail_enabled() && CONFIG.email_2fa_auto_fallback() && user.verified() {
|
||||
TwoFactor::find_by_user_and_type(&user.uuid, TwoFactorType::Email, &conn).await.is_none()
|
||||
} else {
|
||||
false
|
||||
};
|
||||
let fallback_2fa_email = req.reset_two_factor
|
||||
&& CONFIG.mail_enabled()
|
||||
&& CONFIG.email_2fa_auto_fallback()
|
||||
&& user.verified()
|
||||
&& TwoFactor::find_by_user_and_type(&user.uuid, TwoFactorType::Email, &conn).await.is_none();
|
||||
|
||||
// Check the new password before the email below, so that a rejected request doesn't tell the user
|
||||
// their password was reset
|
||||
|
||||
Reference in new issue
Block a user