handleBackgroundMessage function
- RemoteMessage message
Handles background notification messages.
If the dealer app should process the message, it displays the message
using showSystemAppNotification.
Implementation
@pragma('vm:entry-point')
Future<void> handleBackgroundMessage(RemoteMessage message) async {
final container = ProviderContainer();
await _processFcmMessage(
'background',
container: container,
message: message,
onNotifyDevice: (notification) {
if (notification.showSystemNotification) {
return showSystemAppNotification(
container,
toSystemNotification(notification),
);
}
},
);
container.dispose();
}