aboutsummaryrefslogtreecommitdiff
path: root/room.cpp
diff options
context:
space:
mode:
authorKitsune Ral <Kitsune-Ral@users.sf.net>2018-03-05 10:25:46 +0900
committerKitsune Ral <Kitsune-Ral@users.sf.net>2018-03-05 18:36:52 +0900
commite8b6e90feedd4aec3e255984da8952ef716c68db (patch)
tree50881a232ef2dd8ec4fbb4574c565d2110dad7ae /room.cpp
parent1c5b7f8a1c6d82a612f4a2a74eeb644a40370ca5 (diff)
downloadlibquotient-e8b6e90feedd4aec3e255984da8952ef716c68db.tar.gz
libquotient-e8b6e90feedd4aec3e255984da8952ef716c68db.zip
First pieces of server-side read marker support
Diffstat (limited to 'room.cpp')
-rw-r--r--room.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/room.cpp b/room.cpp
index cb94ddb6..4f818473 100644
--- a/room.cpp
+++ b/room.cpp
@@ -402,8 +402,9 @@ void Room::Private::markMessagesAsRead(Room::rev_iter_t upToMarker)
{
if ((*markers.second)->senderId() != q->localUser()->id())
{
- connection->callApi<PostReceiptJob>(
- id, "m.read", (*markers.second)->id());
+ auto eventId = (*markers.second)->id();
+ connection->callApi<PostReceiptJob>(id, "m.read", eventId);
+ setAccountData(ReadMarkerEvent(eventId));
break;
}
}