fix: pagination for blocks with refs when inserting

pull/4800/head^2
Tienson Qin 2022-04-05 11:03:22 +08:00
parent dd1321e1d7
commit 311c1fa96d
1 changed files with 2 additions and 2 deletions

View File

@ -662,8 +662,8 @@
(let [tx-data (:tx-data tx-report)
refs (some->> (filter #(= :block/refs (:a %)) tx-data)
(map :v))
tx-block-ids (distinct (->> (map :e tx-data)
(concat refs)))
tx-block-ids (distinct (-> (map :e tx-data)
(concat refs)))
[tx-id->block cached-id->block] (when (and tx-report result)
(let [blocks (->> (db-utils/pull-many repo-url pull-keys tx-block-ids)
(remove nil?))]