Skip to content

Commit

Permalink
fix: can't link a block via ID & a page in the same block
Browse files Browse the repository at this point in the history
  • Loading branch information
tiensonqin committed Dec 15, 2024
1 parent 8f57de2 commit 4cb793e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions deps/db/src/logseq/db/frontend/content.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,9 @@
[refs]
(sort-by
(fn [ref]
[(boolean (re-find page-ref/page-ref-without-nested-re (:block/title ref)))
(:block/title ref)])
(when-let [title (and (map? ref) (:block/title ref))]
[(boolean (re-find page-ref/page-ref-without-nested-re (:block/title ref)))
title]))
>
refs))

Expand Down

0 comments on commit 4cb793e

Please sign in to comment.