fix: incorrect return values when edn parsing fails for queries

safe-read-string assumed all parsed strings were maps by returning {}
on failure. This could lead to subtle bugs in our new query layer and
other non-map features like hiccup
This commit is contained in:
Gabriel Horner
2024-09-25 11:39:29 -04:00
parent 6363dc11ff
commit 30a652631d
6 changed files with 19 additions and 7 deletions

View File

@@ -105,7 +105,7 @@
"web application/logseq"))))
blocks-str (when blocks-blob (.text blocks-blob))]
(when blocks-str
(common-util/safe-read-string blocks-str))))
(common-util/safe-read-map-string blocks-str))))
(defn- markdown-blocks?
[text]