Merge branch 'krille/fix-mark-story-as-read' into 'main'
fix: Mark story as read See merge request famedly/fluffychat!779
This commit is contained in:
commit
4954f9219d
|
@ -457,12 +457,13 @@ class StoryPageController extends State<StoryPage> {
|
|||
final currentEvent = this.currentEvent;
|
||||
if (currentEvent == null) return;
|
||||
final room = currentEvent.room;
|
||||
if (!currentSeenByUsers.any((u) => u.id == u.room.client.userID)) {
|
||||
room.setReadMarker(
|
||||
currentEvent.eventId,
|
||||
mRead: currentEvent.eventId,
|
||||
);
|
||||
room.client.updateIosBadge();
|
||||
if (index == events.length - 1) {
|
||||
timeline!.setReadMarker();
|
||||
return;
|
||||
}
|
||||
if (!currentSeenByUsers.any((u) => u.id == u.room.client.userID)) {
|
||||
timeline!.setReadMarker(currentEvent.eventId);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue