ソースを参照

fix: empty block references in the right sidebar

Tienson Qin 4 年 前
コミット
f990e3ff40
1 ファイル変更3 行追加2 行削除
  1. 3 2
      src/main/frontend/db/model.cljs

+ 3 - 2
src/main/frontend/db/model.cljs

@@ -1106,8 +1106,9 @@
 
 (defn get-referenced-blocks-ids
   [page-name-or-block-uuid]
-  (if (uuid? page-name-or-block-uuid)
-    (get-block-referenced-blocks-ids page-name-or-block-uuid)
+  (if (util/uuid-string? (str page-name-or-block-uuid))
+    (let [id (uuid page-name-or-block-uuid)]
+      (get-block-referenced-blocks-ids id))
     (get-page-referenced-blocks-ids page-name-or-block-uuid)))
 
 (defn get-matched-blocks