From f181734a46d5bbfde7c5f18a4516b0100a59dce3 Mon Sep 17 00:00:00 2001 From: DorraJaouad Date: Wed, 21 Feb 2024 21:34:51 +0100 Subject: [PATCH] fixup! Fix(MessagesList): skip soft update when needed and make editing a message softer --- src/components/MessagesList/MessagesList.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/MessagesList/MessagesList.vue b/src/components/MessagesList/MessagesList.vue index b8a911efb21..daa5cc33694 100644 --- a/src/components/MessagesList/MessagesList.vue +++ b/src/components/MessagesList/MessagesList.vue @@ -284,7 +284,7 @@ export default { handler(newMessages, oldMessages) { const newGroups = this.prepareMessagesGroups(newMessages) // Check if messages token has changed or if messages were just loaded - if (!!oldMessages || (newMessages.length && newMessages[0].token !== oldMessages?.at(0).token)) { + if (!oldMessages || (newMessages.length && newMessages[0].token !== oldMessages?.at(0)?.token)) { this.messagesGroupedByDateByAuthor = newGroups } else { this.softUpdateByDateGroups(this.messagesGroupedByDateByAuthor, newGroups)