From ed5f0174d7d68ec96992bbc213b5b86d034d56f0 Mon Sep 17 00:00:00 2001 From: Riley Testut Date: Fri, 12 Jan 2024 13:42:19 -0600 Subject: [PATCH] [Delta Sync] Replaces auth error print statements with OSLog --- Delta/Syncing/SyncManager.swift | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Delta/Syncing/SyncManager.swift b/Delta/Syncing/SyncManager.swift index 393a633..afa4b19 100644 --- a/Delta/Syncing/SyncManager.swift +++ b/Delta/Syncing/SyncManager.swift @@ -140,7 +140,7 @@ extension SyncManager } catch { - print("Failed to remove Harmony database.", error) + Logger.sync.error("Failed to remove Harmony database. \(error.localizedDescription, privacy: .public)") } self.start(service: service, completionHandler: completionHandler) @@ -166,11 +166,12 @@ extension SyncManager { case .other(ServiceError.connectionFailed): // Authentication failed due to network connection, but otherwise started successfully so we ignore this error. + Logger.sync.error("Failed to authenticate SyncManager due to network connection (ignoring). \(authError.localizedDescription, privacy: .public)") completionHandler(.success) default: // Another authentication error occured, so we'll deauthenticate ourselves. - print("SyncManager.start auth error:", authError) + Logger.sync.error("Failed to authenticate SyncManager. \(authError.localizedDescription, privacy: .public)") self.deauthenticate() { (result) in switch result @@ -187,7 +188,7 @@ extension SyncManager } catch { - print("SyncManager.start error:", error) + Logger.sync.error("Failed to start SyncManager. \(error.localizedDescription, privacy: .public)") completionHandler(.failure(error)) } }