KeyHandler // Change the path for dumpDOT.

This commit is contained in:
ShikiSuen 2022-09-04 13:26:27 +08:00
parent cd1cffd22e
commit c9d7409cc0
1 changed files with 2 additions and 4 deletions

View File

@ -107,11 +107,9 @@ public class KeyHandler {
// GraphViz
if mgrPrefs.isDebugModeEnabled {
let result = compositor.dumpDOT
let appSupportPath = FileManager.default.urls(for: .cachesDirectory, in: .userDomainMask)[0].path.appending("vChewing-visualization.dot")
do {
try result.write(
toFile: "/private/var/tmp/vChewing-visualization.dot",
atomically: true, encoding: .utf8
)
try result.write(toFile: appSupportPath, atomically: true, encoding: .utf8)
} catch {
IME.prtDebugIntel("Failed from writing dumpDOT results.")
}