mirror of
https://github.com/logseq/logseq.git
synced 2026-04-30 17:06:23 +00:00
Decouple graph-parser util from app util usage
For tiny util heavily used fns like safe-re-find and uuid-string?, decouple graph-parser from so much of the app
This commit is contained in:
@@ -637,7 +637,7 @@
|
||||
(->> (db/get-all-pages repo)
|
||||
(remove (fn [p]
|
||||
(let [name (:block/name p)]
|
||||
(or (gp-util/uuid-string? name)
|
||||
(or (util/uuid-string? name)
|
||||
(gp-config/draw? name)
|
||||
(db/built-in-pages-names (string/upper-case name))))))
|
||||
(common-handler/fix-pages-timestamps)))
|
||||
@@ -691,7 +691,7 @@
|
||||
chosen (if (string/starts-with? chosen "New page: ") ;; FIXME: What if a page named "New page: XXX"?
|
||||
(subs chosen 10)
|
||||
chosen)
|
||||
chosen (if (and (gp-util/safe-re-find #"\s+" chosen) (not wrapped?))
|
||||
chosen (if (and (util/safe-re-find #"\s+" chosen) (not wrapped?))
|
||||
(util/format "[[%s]]" chosen)
|
||||
chosen)
|
||||
q (if @editor-handler/*selected-text "" q)
|
||||
|
||||
Reference in New Issue
Block a user