From 8085f73c1d7d8e1bdaf4a730af975ea831dc3ce6 Mon Sep 17 00:00:00 2001 From: link2xt Date: Thu, 4 Apr 2024 17:18:09 +0000 Subject: [PATCH] swift --- deltachat-ios/AppDelegate.swift | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/deltachat-ios/AppDelegate.swift b/deltachat-ios/AppDelegate.swift index 3da948ca19..67f699a097 100644 --- a/deltachat-ios/AppDelegate.swift +++ b/deltachat-ios/AppDelegate.swift @@ -497,7 +497,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UNUserNotificationCenterD UserDefaults.self.pushToDebugArray("ERR2") } - if !appIsInForeground() { + if !self.appIsInForeground() { UserDefaults.setMainIoRunning(false) // this also improves resilience: if we crashed before, NSE would never run otherwise } @@ -601,13 +601,13 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UNUserNotificationCenterD let eventHandler = DcEventHandler(dcAccounts: self.dcAccounts) let eventEmitter = self.dcAccounts.getEventEmitter() logger.info("➡️ event emitter started") - while !shouldShutdownEventLoop { + while !self.shouldShutdownEventLoop { guard let event = eventEmitter.getNextEvent() else { break } eventHandler.handleEvent(event: event) } logger.info("⬅️ event emitter finished") - eventShutdownSemaphore.signal() - eventHandlerActive = false + self.eventShutdownSemaphore.signal() + self.eventHandlerActive = false } }