fetchChatRoomMuteList method
Gets the list of members who are muted in the chat room from the server.
Only the chat room owner or admin can call this method.
Param roomId
The chat room ID.
Param pageNum
The page number, starting from 1.
Param pageSize
The number of muted members per page.
Return The muted member list.
Throws A description of the exception. See ChatError.
Implementation
Future<List<String>> fetchChatRoomMuteList(
String roomId, {
int pageNum = 1,
int pageSize = 200,
}) async {
Map req = {"roomId": roomId, "pageNum": pageNum, "pageSize": pageSize};
Map result =
await _channel.invokeMethod(ChatMethodKeys.fetchChatRoomMuteList, req);
try {
ChatError.hasErrorFromResult(result);
return result[ChatMethodKeys.fetchChatRoomMuteList]?.cast<String>() ?? [];
} on ChatError catch (e) {
throw e;
}
}