Clear typing indicator after receiving edits

This commit is contained in:
Fedor Indutny 2023-05-31 11:14:38 -07:00 committed by GitHub
parent 9c325ea724
commit 3abacb25ce
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 9 additions and 2 deletions

View file

@ -272,9 +272,12 @@ export async function handleEditMessage(
);
drop(mainMessageModel.getConversation()?.updateLastMessage());
// Update notifications
if (conversation) {
// Clear typing indicator
const typingToken = `${editAttributes.fromId}.${editAttributes.fromDevice}`;
conversation.clearContactTypingTimer(typingToken);
// Update notifications
if (await shouldReplyNotifyUser(mainMessageModel, conversation)) {
await conversation.notify(mainMessageModel);
}