Mark messages as read while chat is open

Fixes #97.
parent 154f6b60
......@@ -86,7 +86,10 @@ class ChatPageState extends State<ChatPage> {
}
});
bloc.shouldRefresh.listen((shouldRefresh) => setState(() {}));
bloc.shouldRefresh.listen((shouldRefresh) {
setState(() {});
bloc.markAllAsRead();
});
}
@override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment