Browse Source

fix: url pathname needs to be decoded too

Tienson Qin 5 months ago
parent
commit
c49ab05cd5
1 changed files with 1 additions and 1 deletions
  1. 1 1
      deps/common/src/logseq/common/path.cljs

+ 1 - 1
deps/common/src/logseq/common/path.cljs

@@ -226,7 +226,7 @@
                                         (str "original-url: " original-url
                                         (str "original-url: " original-url
                                              " url: " (string/replace (safe-decode-uri-component original-url) "assets://" "file://")))
                                              " url: " (string/replace (safe-decode-uri-component original-url) "assets://" "file://")))
                       (throw e)))
                       (throw e)))
-          path (.-pathname url)
+          path (safe-decode-uri-component (.-pathname url))
           host (.-host url)
           host (.-host url)
           path (if (string/starts-with? path "///")
           path (if (string/starts-with? path "///")
                  (subs path 2)
                  (subs path 2)