This commit is contained in:
rustmailer
2026-04-05 16:06:07 +08:00
parent 8b4dc44c07
commit 286ae16057
38 changed files with 2634 additions and 3640 deletions
+2 -5
View File
@@ -32,10 +32,10 @@ use crate::{
since::{DateSince, RelativeDate},
state::AccountRunningState,
},
blob::{manager::ENVELOPE_INDEX_MANAGER, storage::BLOB_MANAGER},
cache::imap::mailbox::MailBox,
database::{list_all_impl, secondary_find_impl, with_transaction},
error::BichonResult,
store::tantivy::manager::INDEX_MANAGER,
users::{role::DEFAULT_ACCOUNT_MANAGER_ROLE_ID, UserModel, DEFAULT_ADMIN_USER_ID},
},
utc_now,
@@ -359,10 +359,7 @@ impl AccountV4 {
OAuth2AccessToken::try_delete(account.id).await?;
UserModel::cleanup_account(account.id).await?;
MailBox::clean(account.id).await?;
let content_hashes = ENVELOPE_INDEX_MANAGER
.delete_account_envelopes(account.id)
.await?;
BLOB_MANAGER.delete(&content_hashes, &content_hashes)?;
INDEX_MANAGER.delete_account_envelopes(account.id).await?;
Self::delete_account(account.id).await?;
info!("Sequential cleanup completed for account: {}", account.id);
Ok(())