updateEventAccordingToAcknowledgedData method

void updateEventAccordingToAcknowledgedData()

Checks for any missed notifications and updates respective notification

Implementation

void updateEventAccordingToAcknowledgedData() async {
  await Future.forEach((allLocationNotifications),
      (dynamic notification) async {
    if (notification.key.contains(MixedConstants.SHARE_LOCATION)) {
      if ((notification.locationNotificationModel.atsignCreator ==
              currentAtSign) &&
          (!notification.locationNotificationModel.isAcknowledgment)) {
        forShareLocation(notification);
      }
    } else if (notification.key.contains(MixedConstants.REQUEST_LOCATION)) {
      if ((notification.locationNotificationModel.atsignCreator ==
              currentAtSign) &&
          (!notification.locationNotificationModel.isAcknowledgment)) {
        forRequestLocation(notification);
      }
    }
  });
}