subscribe static method

Future<void> subscribe()

Implementation

static Future<void> subscribe() async {
  FirebaseMessaging.onBackgroundMessage(_firebaseMessagingBackgroundHandler);

  await _requestPermission();

  final fcmToken = await _firebaseMessaging.getToken();
  await InngageService.registerSubscriber(fcmToken);

  await receiveNotificationForeground();
  await receiveNotificationClosed();

  await _config();
}