From beebaf7b68b3749f4a1bc4d916e23906b8c16d7f Mon Sep 17 00:00:00 2001
From: Ariver <ar@MacBook-Air.local>
Date: Wed, 13 May 2026 23:31:23 +0800
Subject: [PATCH] Release TagLauncher 5.6.0

---
 Apptag/ApptagApp.swift |   16 ++++++++++------
 1 files changed, 10 insertions(+), 6 deletions(-)

diff --git a/Apptag/ApptagApp.swift b/Apptag/ApptagApp.swift
index 9698519..76f0549 100644
--- a/Apptag/ApptagApp.swift
+++ b/Apptag/ApptagApp.swift
@@ -588,6 +588,7 @@
                 try TagDatabase.exportTo(url)
             } catch {
                 fputs("[TagLauncher] Export failed: \(error)\n", stderr)
+                showDataAlert(title: tr("settings.exportFailed"), message: error.localizedDescription)
             }
         }
     }
@@ -604,16 +605,19 @@
                 scanApps()
             } catch {
                 fputs("[TagLauncher] Import failed: \(error)\n", stderr)
-                // Show alert on failure
-                let alert = NSAlert()
-                alert.messageText = tr("settings.importFailed")
-                alert.informativeText = error.localizedDescription
-                alert.alertStyle = .warning
-                alert.runModal()
+                showDataAlert(title: tr("settings.importFailed"), message: error.localizedDescription)
             }
         }
     }
 
+    private func showDataAlert(title: String, message: String) {
+        let alert = NSAlert()
+        alert.messageText = title
+        alert.informativeText = message
+        alert.alertStyle = .warning
+        alert.runModal()
+    }
+
     private var appVersion: String {
         Bundle.main.infoDictionary?["CFBundleShortVersionString"] as? String ?? "?"
     }

--
Gitblit v1.9.3