aboutsummaryrefslogtreecommitdiff
path: root/libdino
diff options
context:
space:
mode:
authorfiaxh <git@lightrise.org>2023-01-13 11:23:09 +0100
committerfiaxh <git@lightrise.org>2023-01-13 11:44:28 +0100
commit73c0263f35a73b68d20d299ee7fe8c37b9a6ffeb (patch)
tree5ccc55e0b8a6324199559abac590bc1da99bc6b6 /libdino
parent860c72bfc93d252d45eb97e71cf9ff22985c7ef9 (diff)
downloaddino-73c0263f35a73b68d20d299ee7fe8c37b9a6ffeb.tar.gz
dino-73c0263f35a73b68d20d299ee7fe8c37b9a6ffeb.zip
Add debug outputs to summarize_whitespaces_to_space and don't assert_not_reached
related #1335
Diffstat (limited to 'libdino')
-rw-r--r--libdino/src/service/content_item_store.vala5
1 files changed, 5 insertions, 0 deletions
diff --git a/libdino/src/service/content_item_store.vala b/libdino/src/service/content_item_store.vala
index b3e32cf4..c3d9d006 100644
--- a/libdino/src/service/content_item_store.vala
+++ b/libdino/src/service/content_item_store.vala
@@ -121,6 +121,8 @@ public class ContentItemStore : StreamInteractionModule, Object {
Message? message = get_message_for_content_item(conversation, content_item);
if (message == null) return null;
+ if (message.edit_to != null) return message.edit_to;
+
if (conversation.type_ == Conversation.Type.CHAT) {
return message.stanza_id;
} else {
@@ -131,6 +133,9 @@ public class ContentItemStore : StreamInteractionModule, Object {
public Jid? get_message_sender_for_content_item(Conversation conversation, ContentItem content_item) {
Message? message = get_message_for_content_item(conversation, content_item);
if (message == null) return null;
+
+ // No need to look at edit_to, because it's the same sender JID.
+
return message.from;
}