fix multiple bugs with query builder construction

Bug was caused by query string updates relying on q-str which is
only valid on initial render. Subsequent changes changes to query
caused bugs

fixes #10263, fixes #10264 and fixes #9159
pull/10489/head^2
Gabriel Horner 2023-11-09 13:52:03 -05:00 committed by Andelf
parent 1e87616fbd
commit 57e759aad1
1 changed files with 2 additions and 2 deletions

View File

@ -449,8 +449,8 @@
block (db/pull [:block/uuid (:block/uuid block)])]
(when block
(let [content (string/replace (:block/content block)
(util/format "{{query %s" q-str)
(util/format "{{query %s" q))]
#"\{\{query[^}]+\}\}"
(util/format "{{query %s}}" q))]
(editor-handler/save-block! repo (:block/uuid block) content)))))))
(assoc state ::tree *tree)))
:will-mount (fn [state]