aboutsummaryrefslogtreecommitdiff
path: root/libdino/src/service/message_storage.vala
diff options
context:
space:
mode:
authorfiaxh <git@lightrise.org>2020-04-28 23:37:01 +0200
committerfiaxh <git@lightrise.org>2020-04-28 23:56:53 +0200
commitcd3a119eff66a9e8cbd48d418c1e02f29dca4b41 (patch)
tree3dc51707a8ce5cf4a903c4b5eacad55fe3b1fb11 /libdino/src/service/message_storage.vala
parent3b6e8700b4638d15f766906794e8ddc82dd03edb (diff)
downloaddino-cd3a119eff66a9e8cbd48d418c1e02f29dca4b41.tar.gz
dino-cd3a119eff66a9e8cbd48d418c1e02f29dca4b41.zip
Handle incoming own read marker in private MUCs
Diffstat (limited to 'libdino/src/service/message_storage.vala')
-rw-r--r--libdino/src/service/message_storage.vala8
1 files changed, 8 insertions, 0 deletions
diff --git a/libdino/src/service/message_storage.vala b/libdino/src/service/message_storage.vala
index 50fc94b3..4dbc05a7 100644
--- a/libdino/src/service/message_storage.vala
+++ b/libdino/src/service/message_storage.vala
@@ -100,6 +100,14 @@ public class MessageStorage : StreamInteractionModule, Object {
return null;
}
+ public Message? get_message_by_server_id(string server_id, Conversation conversation) {
+ init_conversation(conversation);
+ foreach (Message message in messages[conversation]) {
+ if (message.server_id == server_id) return message;
+ }
+ return null;
+ }
+
public Conversation? get_conversation_for_stanza_id(Account account, string stanza_id) {
foreach (Conversation conversation in messages.keys) {
if (!conversation.account.equals(account)) continue;