deleteMessagesForMe method

  1. @override
Future deleteMessagesForMe(
  1. String jid,
  2. String chatType,
  3. List<String> messageIds,
  4. bool? isMediaDelete,
)
override

Implementation

@override
Future<dynamic> deleteMessagesForMe(String jid, String chatType,
    List<String> messageIds, bool? isMediaDelete) async {
  dynamic messageDeleteResponse;
  try {
    messageDeleteResponse =
        await mirrorFlyMethodChannel.invokeMethod('deleteMessagesForMe', {
      "jid": jid,
      "chat_type": chatType,
      "isMediaDelete": isMediaDelete,
      "message_ids": messageIds
    });
    debugPrint("deleteMessagesForMe Response ==> $messageDeleteResponse");
    return messageDeleteResponse;
  } on PlatformException catch (e) {
    debugPrint("Platform Exception ===> $e");
    rethrow;
  } on Exception catch (error) {
    debugPrint("Exception ==> $error");
    rethrow;
  }
}