aboutsummaryrefslogtreecommitdiff
path: root/libdino/src
diff options
context:
space:
mode:
authorfiaxh <git@lightrise.org>2022-01-01 19:47:46 +0100
committerfiaxh <git@lightrise.org>2022-01-01 19:47:46 +0100
commit6b8ad7a1044f3f01cc0789e912800350a64c0c2c (patch)
treee1d9d6be43ccd882042abe6c50679b067e2f1b93 /libdino/src
parent839be0e316bf756ddccb9eba17b75c974440093c (diff)
downloaddino-6b8ad7a1044f3f01cc0789e912800350a64c0c2c.tar.gz
dino-6b8ad7a1044f3f01cc0789e912800350a64c0c2c.zip
Fix delivery error displaying for MUC PMs
fixes #1113
Diffstat (limited to 'libdino/src')
-rw-r--r--libdino/src/service/message_processor.vala10
1 files changed, 7 insertions, 3 deletions
diff --git a/libdino/src/service/message_processor.vala b/libdino/src/service/message_processor.vala
index 4fe1f6c3..6445ce40 100644
--- a/libdino/src/service/message_processor.vala
+++ b/libdino/src/service/message_processor.vala
@@ -144,9 +144,13 @@ public class MessageProcessor : StreamInteractionModule, Object {
}
});
stream_interactor.module_manager.get_module(account, Xmpp.MessageModule.IDENTITY).received_error.connect((stream, message_stanza, error_stanza) => {
- Conversation? conversation = stream_interactor.get_module(ConversationManager.IDENTITY).get_conversation(message_stanza.from.bare_jid, account);
- if (conversation == null) return;
- Message? message = stream_interactor.get_module(MessageStorage.IDENTITY).get_message_by_stanza_id(message_stanza.id, conversation);
+ Message? message = null;
+
+ Gee.List<Conversation> conversations = stream_interactor.get_module(ConversationManager.IDENTITY).get_conversations(message_stanza.from, account);
+ foreach (Conversation conversation in conversations) {
+ message = stream_interactor.get_module(MessageStorage.IDENTITY).get_message_by_stanza_id(message_stanza.id, conversation);
+ if (message != null) break;
+ }
if (message == null) return;
// We don't care about delivery errors if our counterpart already ACKed the message.
if (message.marked in Message.MARKED_RECEIVED) return;