From da888172afa5ea2579f4def499fcc9d7cc6c312b Mon Sep 17 00:00:00 2001 From: Dung Le Date: Thu, 4 Jul 2019 10:52:55 +0700 Subject: [PATCH] Remove old logging cleanup We don't log like this anymore, so it's best to just remove it. --- Sources/XiEditor/AppDelegate.swift | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/Sources/XiEditor/AppDelegate.swift b/Sources/XiEditor/AppDelegate.swift index 78c15f3e..d353a301 100644 --- a/Sources/XiEditor/AppDelegate.swift +++ b/Sources/XiEditor/AppDelegate.swift @@ -123,9 +123,6 @@ class AppDelegate: NSObject, NSApplicationDelegate { return applicationDirectory }() - // The default name for XiEditor's error logs - let defaultCoreLogName = "xi_tmp.log" - lazy var errorLogDirectory: URL? = { let logDirectory = FileManager.default.urls( for: .libraryDirectory, @@ -191,17 +188,6 @@ class AppDelegate: NSObject, NSApplicationDelegate { renameCliToggle() } - // Clean up temporary Xi stderr log - func applicationWillTerminate(_ notification: Notification) { - if let tmpErrLogFile = errorLogDirectory?.appendingPathComponent(defaultCoreLogName) { - do { - try FileManager.default.removeItem(at: tmpErrLogFile) - } catch let err as NSError { - print("Failed to remove temporary log file. \(err)") - } - } - } - // MARK: - CLI Menu Items @IBOutlet weak var cliToggle: NSMenuItem!