From 990e63db53779bf8433b58ce8a470c51afb72957 Mon Sep 17 00:00:00 2001 From: Morgan Pretty Date: Mon, 24 Mar 2025 10:12:37 +1100 Subject: [PATCH] Revert an unintended change --- Session/Meta/AppDelegate.swift | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Session/Meta/AppDelegate.swift b/Session/Meta/AppDelegate.swift index 15dac97e8..0dfefa7c5 100644 --- a/Session/Meta/AppDelegate.swift +++ b/Session/Meta/AppDelegate.swift @@ -381,7 +381,10 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UNUserNotificationCenterD // Ensure we haven't timed out yet guard timer.isCancelled == false else { return } - /// Update the app badge in case the unread count changed + // Immediately cancel the timer to prevent the timeout being triggered + timer.cancel() + + // Update the app badge in case the unread count changed if let unreadCount: Int = dependencies[singleton: .storage].read({ db in try Interaction.fetchAppBadgeUnreadCount(db, using: dependencies)