diff --git a/WooCommerce/Classes/Notifications/PushNotificationsManager.swift b/WooCommerce/Classes/Notifications/PushNotificationsManager.swift index 73f6617525e..8aace869996 100644 --- a/WooCommerce/Classes/Notifications/PushNotificationsManager.swift +++ b/WooCommerce/Classes/Notifications/PushNotificationsManager.swift @@ -477,6 +477,7 @@ private extension PushNotificationsManager { /// Handles a remote notification while the app is inactive. /// /// - Parameter notification: Push notification content from a remote notification. + @MainActor func handleInactiveRemoteNotification(notification: PushNotification) async { guard applicationState == .inactive else { return diff --git a/WooCommerce/Classes/ViewRelated/MainTabBarController.swift b/WooCommerce/Classes/ViewRelated/MainTabBarController.swift index 93e245a91f4..ed25658deb2 100644 --- a/WooCommerce/Classes/ViewRelated/MainTabBarController.swift +++ b/WooCommerce/Classes/ViewRelated/MainTabBarController.swift @@ -337,10 +337,8 @@ extension MainTabBarController { } let siteID = Int64(note.meta.identifier(forKey: .site) ?? Int.min) - switchToStore(with: siteID, onCompletion: { siteChanged in - if siteChanged { - presentNotificationDetails(for: note) - } + switchToStore(with: siteID, onCompletion: { _ in + presentNotificationDetails(for: note) }) } ServiceLocator.stores.dispatch(action)