From 1ab8b85f06b9ce294dacba61e732ee07889b2883 Mon Sep 17 00:00:00 2001 From: Carl Schwan Date: Thu, 15 Feb 2024 16:55:20 +0100 Subject: [PATCH] Fix reaction update event when the event is not there anymore Happens when interacting witht Mjonir quite often (cherry picked from commit 6d3839dd42d867c3511058debe3b25faf28238d9) --- src/models/reactionmodel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/models/reactionmodel.cpp b/src/models/reactionmodel.cpp index b4f8cab9d..9586f44e5 100644 --- a/src/models/reactionmodel.cpp +++ b/src/models/reactionmodel.cpp @@ -23,7 +23,7 @@ ReactionModel::ReactionModel(const Quotient::RoomMessageEvent *event, const NeoC { if (m_event != nullptr && m_room != nullptr) { connect(m_room, &NeoChatRoom::updatedEvent, this, [this](const QString &eventId) { - if (m_event->id() == eventId) { + if (m_event && m_event->id() == eventId) { updateReactions(); } });