You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
notif: Use associated account as initial account; if opened from background
Previously, when two accounts (Account-1 and Account-2) were
logged in, the app always defaulted to showing the home page
of Account-1 on launch. If the app was closed and the user
opened a notification from Account-2, the navigation stack
would be:
HomePage(Account-1) -> MessageListPage(Account-2)
This commit fixes that behaviour, now when a notification is
opened while the app is closed, the home page will correspond
to the account associated with the notification's conversation.
This addresses zulip#1210 for background notifications.
if (!context.mounted) return; // TODO(linter): this is impossible as there's no actual async gap, but the use_build_context_synchronously lint doesn't see that
470
501
471
-
final zulipLocalizations =ZulipLocalizations.of(context);
472
-
final globalStore =GlobalStoreWidget.of(context);
473
-
final account = globalStore.accounts.firstWhereOrNull((account) =>
0 commit comments