clearAllGroupsFromLocal method

Future<void> clearAllGroupsFromLocal()

~english Clears all groups of the current user from the local database.

Returns None.

Throws Exception description, see EMError. ~end

~chinese 清理数据库中当前用户的所有群组。

Return 无。

Throws 如果有异常会在这里抛出,包含错误码和错误描述,详见 EMError。 ~end

Implementation

Future<void> clearAllGroupsFromLocal() async {
  Map result = await Client.instance.groupManager
      .callNativeMethod(ChatMethodKeys.clearAllGroupsFromDB);
  try {
    EMError.hasErrorFromResult(result);
  } catch (e) {
    rethrow;
  }
}