More explicit

This commit is contained in:
Hocuri
2020-06-13 20:26:16 +02:00
parent ae2fd4014a
commit 86bc54508f
4 changed files with 9 additions and 7 deletions

View File

@@ -313,12 +313,9 @@ impl Imap {
let lock = context.wrong_pw_warning_mutex.lock().await;
if self.login_failed_once
&& !context.get_config_bool(Config::WarnedAboutWrongPw).await
&& context.get_config_bool(Config::NotifyAboutWrongPw).await
{
if let Err(e) = context
.set_config(Config::WarnedAboutWrongPw, Some("1"))
.await
{
if let Err(e) = context.set_config(Config::NotifyAboutWrongPw, None).await {
warn!(context, "{}", e);
}
drop(lock);