Sync broadcast subscribers list (#7578)

fix #7497
This commit is contained in:
Hocuri
2026-01-13 15:04:51 +01:00
committed by GitHub
parent c3a6e48882
commit d446a16fc6
3 changed files with 135 additions and 3 deletions

View File

@@ -596,8 +596,15 @@ pub(crate) async fn handle_securejoin_handshake(
// Join group.
chat::add_contact_to_chat_ex(context, Nosync, joining_chat_id, contact_id, true)
.await?;
let chat = Chat::load_from_db(context, joining_chat_id).await?;
if chat.typ == Chattype::OutBroadcast {
// We don't use the membership consistency algorithm for broadcast channels,
// so, sync the memberlist when adding a contact
chat.sync_contacts(context).await.log_err(context).ok();
}
inviter_progress(context, contact_id, joining_chat_id, chat.typ)?;
// IMAP-delete the message to avoid handling it by another device and adding the
// member twice. Another device will know the member's key from Autocrypt-Gossip.