forwardMessagesToMultipleUsers method
Future<void>
forwardMessagesToMultipleUsers(
- List<
String> messageIds, - List<
String> userList, - dynamic callback(
- FlyResponse response
override
This method is used to forward the multiple messages.
Implementation
@override
Future<void> forwardMessagesToMultipleUsers(List<String> messageIds,
List<String> userList, Function(FlyResponse response)? callback) async {
//forwardMessage
bool? forwardMessageResponse;
try {
forwardMessageResponse = await mirrorFlyMethodChannel.invokeMethod<bool>(
'forwardMessagesToMultipleUsers',
{"message_ids": messageIds, "userList": userList});
LogMessage.d("Forward Msg Response ", " $forwardMessageResponse");
callback?.call(FlyResponse(true, FlyConstants.empty, FlyConstants.empty));
// return forwardMessageResponse;
} on PlatformException catch (e) {
LogMessage.d("Platform Exception =", " $e");
callback?.call(FlyResponse(false, FlyConstants.empty, FlyConstants.empty,
FlyException(e.code, e.message, e.details)));
} on Exception catch (e) {
LogMessage.d("Exception ", " $e");
callback?.call(FlyResponse(false, FlyConstants.empty, FlyConstants.empty,
FlyException(FlyErrorCode.unHandle, FlyErrorMessage.unHandle, e)));
}
}