From cdabd7fd73a0cb8cb05a2dd6f790a9770643aaca Mon Sep 17 00:00:00 2001 From: Chris Badahdah Date: Sun, 22 Dec 2024 17:30:37 -0700 Subject: [PATCH] Fix WSL regression caused by 73e0070 --- src/portal/runtime/browser.cljc | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/portal/runtime/browser.cljc b/src/portal/runtime/browser.cljc index 7990ebfa..9f23a875 100644 --- a/src/portal/runtime/browser.cljc +++ b/src/portal/runtime/browser.cljc @@ -77,7 +77,7 @@ (str/trim (:out (shell/sh "cmd.exe" "/C" "echo %USERNAME%")))) (defn- windows-chrome-web-applications [] - (some + (mapcat (fn [root] (tree-seq (fn [f] @@ -85,12 +85,15 @@ (or (str/includes? f "_crx_") (str/ends-with? f "Web Applications")))) - (fn [d] (fs/list d)) + (fn [d] + (try + (fs/list d) + (catch #?(:cljs :default :default Exception) _))) (fs/join root (get-windows-user) "AppData/Local/Google/Chrome/User Data/Default/Web Applications"))) - ["/Users" "/mnt/c/Users"])) + ["/mnt/c/Users" "/Users"])) (defn- get-app-id-profile-windows [app-name] (try