Skip to content

Commit

Permalink
fix(fs): avoid EEXISTS error reporting for mkdir
Browse files Browse the repository at this point in the history
  • Loading branch information
andelf authored and tiensonqin committed Dec 8, 2023
1 parent 2318e85 commit 099cad5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/frontend/fs/node.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
(-> (ipc/ipc "mkdir" dir)
(p/then (fn [_] (js/console.log (str "Directory created: " dir))))
(p/catch (fn [error]
(when (not= (.-code error) "EEXIST")
(when-not (string/includes? (str error) "EEXIST")
(js/console.error (str "Error creating directory: " dir) error))))))

(mkdir-recur! [_this dir]
Expand Down

0 comments on commit 099cad5

Please sign in to comment.