updateGroupAnnouncement method
Updates the group announcement.
Only the group owner or admin can call this method.
Param groupId
The group ID.
Param announcement
The group announcement.
Throws A description of the exception. See ChatError.
Implementation
Future<void> updateGroupAnnouncement(
String groupId,
String announcement,
) async {
Map req = {'groupId': groupId, 'announcement': announcement};
Map result = await _channel.invokeMethod(
ChatMethodKeys.updateGroupAnnouncement, req);
try {
ChatError.hasErrorFromResult(result);
} on ChatError catch (e) {
throw e;
}
}