fix: Delete user-deleted messages on the server even if they show up on IMAP later

Before, if the user deleted a message too quickly after sending, it was deleted only locally. The
fix is to remember for tombstones that the corresponding message should be deleted on the server
too.
This commit is contained in:
iequidoo
2024-03-27 22:09:55 -03:00
committed by iequidoo
parent f436e915d3
commit 13f58e0ca5
8 changed files with 71 additions and 37 deletions

View File

@@ -2043,7 +2043,7 @@ async fn test_dont_assign_to_trash_by_parent() {
assert_eq!(msg.text, "Hi hello");
println!("\n========= Delete the message ==========");
msg.id.trash(&t).await.unwrap();
msg.id.trash(&t, false).await.unwrap();
let msgs = chat::get_chat_msgs(&t.ctx, chat_id).await.unwrap();
assert_eq!(msgs.len(), 0);