fix: ContactId::set_name_ex(): Emit ContactsChanged when transaction is completed

This fixes flaky JSON-RPC's `test_rename_synchronization()`.
This commit is contained in:
iequidoo
2025-11-16 18:40:19 -03:00
committed by iequidoo
parent 88d213fcdb
commit d44e2420bc

View File

@@ -130,13 +130,15 @@ impl ContactId {
Ok((addr, fingerprint)) Ok((addr, fingerprint))
}, },
)?; )?;
context.emit_event(EventType::ContactsChanged(Some(self)));
Ok(Some((addr, fingerprint))) Ok(Some((addr, fingerprint)))
} else { } else {
Ok(None) Ok(None)
} }
}) })
.await?; .await?;
if row.is_some() {
context.emit_event(EventType::ContactsChanged(Some(self)));
}
if sync.into() if sync.into()
&& let Some((addr, fingerprint)) = row && let Some((addr, fingerprint)) = row