File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
deps/cli/src/logseq/cli/common/mcp Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change 55 [logseq.common.util :as common-util]
66 [logseq.common.util.date-time :as date-time-util]
77 [logseq.db :as ldb]
8+ [logseq.db.frontend.content :as db-content]
89 [logseq.db.frontend.class :as db-class]
910 [logseq.db.frontend.entity-util :as entity-util]
1011 [logseq.db.frontend.property :as db-property]
6970
7071(defn- get-page-blocks
7172 [db page-id]
72- (let [blocks (ldb/get-page-blocks db page-id)]
73+ (let [datoms (d/datoms db :avet :block/page page-id)
74+ block-eids (mapv :e datoms)
75+ block-ents (map #(d/entity db %) block-eids)
76+ blocks (map #(assoc % :block/title (db-content/recur-replace-uuid-in-block-title %)) block-ents)]
7377 ; ; Use repo stub since this is a DB only tool
7478 (->> (otree/blocks->vec-tree " logseq_db_repo_stub" db blocks page-id)
7579 (map #(update % :block/uuid str)))))
You can’t perform that action at this time.
0 commit comments