소스 검색

【APPCenter】Crash编号:103 -- 修复

lizhe 10 달 전
부모
커밋
604d52bc63
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      PDF Office/PDF Master/Class/PDFWindowController/ViewController/KMMainViewController+Action.swift

+ 2 - 1
PDF Office/PDF Master/Class/PDFWindowController/ViewController/KMMainViewController+Action.swift

@@ -2461,7 +2461,8 @@ extension KMMainViewController {
                 }
             }
         } else {
-            let file: URL = (self.myDocument?.fileURL)!
+            guard let url = self.myDocument?.fileURL else { return }
+            let file: URL = url
             if FileManager.default.fileExists(atPath: file.path) {
                 NSWorkspace.shared.activateFileViewerSelecting([file])
             }