fixed stale state after logout and replayed or lost share intents
This commit is contained in:
@@ -4,6 +4,7 @@ import 'package:crypton/crypton.dart';
|
||||
import 'package:firebase_messaging/firebase_messaging.dart';
|
||||
|
||||
import '../background/widget_background_task.dart';
|
||||
import '../model/account_data.dart';
|
||||
import '../notification/notification_service.dart';
|
||||
import 'chat_thread_store.dart';
|
||||
import 'nid_store.dart';
|
||||
@@ -54,6 +55,8 @@ PushKind classifyPush(Map<String, dynamic> data) {
|
||||
/// "must be annotated"), so a plain function is the reliable form.
|
||||
@pragma('vm:entry-point')
|
||||
Future<void> pushOnBackgroundMessage(RemoteMessage message) async {
|
||||
// This engine outlives sign-outs and logins in the app.
|
||||
await AccountData().reloadFromStorage();
|
||||
await NotificationService().initializeNotifications();
|
||||
await PushRenderer.ensureChannels();
|
||||
await PushMessageHandler().handle(message);
|
||||
|
||||
Reference in New Issue
Block a user