recallMessage method Null safety

Future<void> recallMessage(
  1. String messageId
)

Recalls the sent message.

Param messageId The message ID.

Throws A description of the exception. See {@link EMError}.

Implementation

Future<void> recallMessage(String messageId) async {
  Map req = {"msg_id": messageId};
  Map result = await EMMethodChannel.ChatManager.invokeMethod(
      ChatMethodKeys.recallMessage, req);
  try {
    EMError.hasErrorFromResult(result);
  } on EMError catch (e) {
    throw e;
  }
}