fix: Remove group member locally even if send_msg() fails (#5508)

Otherwise it's impossible to remove a member with missing key from a protected group. In the worst
case a removed member will be added back due to the group membership consistency algo.
This commit is contained in:
iequidoo
2024-05-30 16:57:22 -03:00
committed by iequidoo
parent 980bab3040
commit 24a06d175e
6 changed files with 49 additions and 9 deletions

View File

@@ -1403,6 +1403,7 @@ First thread."#;
let alice_bob_contact_id = Contact::create(&alice, "Bob", "bob@example.net").await?;
remove_contact_from_chat(&alice, alice_chat_id, alice_bob_contact_id).await?;
alice.pop_sent_msg().await;
// The message from Bob is delivered late, Bob is already removed.
let msg = alice.recv_msg(&sent).await;