fix(imap): reset new_mail if folder is ignored

This prevents skipping IDLE in infinite loop
if folder is not fetched.
This happens on the INBOX
when OnlyFetchMvbox setting is enabled.
This commit is contained in:
link2xt
2024-07-01 20:44:15 +00:00
parent 5fa7cff468
commit 5792d7b18d

View File

@@ -540,6 +540,7 @@ impl Imap {
) -> Result<bool> {
if should_ignore_folder(context, folder, folder_meaning).await? {
info!(context, "Not fetching from {folder:?}.");
session.new_mail = false;
return Ok(false);
}