markRead method
Mark all messages as read.
Optionally provide a messageId
if you want to mark a
particular message as read.
Implementation
Future<EmptyResponse> markRead({String? messageId}) async {
_checkInitialized();
client.state.totalUnreadCount =
max(0, (client.state.totalUnreadCount) - (state!.unreadCount));
state!.unreadCount = 0;
return _client.markChannelRead(id!, type, messageId: messageId);
}