searchLocalConversations method

Future<Map> searchLocalConversations(
  1. dynamic config
)

Implementation

Future<Map<dynamic, dynamic>> searchLocalConversations(dynamic config) async {
  Object _config = mapToJSObj(config);
  final result = await promiseToFuture(
          ZIM.getInstance()!.searchLocalConversations(_config))
      .catchError((e) {
    throw PlatformException(code: e.code.toString(), message: e.message);
  });

  final resultMap = jsObjectToMap(result);

  resultMap['nextFlag'] =
      resultMap['nextFlag'] is int ? resultMap['nextFlag'] : 0;

  return resultMap;
}