getNotificationData method

  1. @override
NotificationData getNotificationData(
  1. dynamic data,
  2. String channel
)
override

Implementation

@override
NotificationData getNotificationData(data, String channel) {
  final notification = NotificationBuilder()
      .setTitle(data?.data?.title)
      .setSubtitle(data?.data?.subtitle)
      .setBody(data?.data?.body)
      .setPlatform(PlatformType.ios)
      .setImage(data?.data?.image ?? '')
      .setUrl(data?.data?.url ?? '')
      .build();
  return notification;
}