Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:art: After invoking kernel API `setBlockAttrs` then auto refresh dynamic anchor text of block refs Fix https://github.com/siyuan-note/siyuan/issues/8605

Danielbb0bbaf5a0c0
diff --git a/kernel/model/blockial.go b/kernel/model/blockial.go
index 63e3c7e156..64575b0109 100644
--- a/kernel/model/blockial.go
+++ b/kernel/model/blockial.go
@@ -138,7 +138,9 @@ func setNodeAttrs(node *ast.Node, tree *parse.Tree, nameValues map[string]string
pushBroadcastAttrTransactions(oldAttrs, node)
go func() {
- sql.WaitForWritingDatabase()
+ if !sql.IsEmptyQueue() {
+ sql.WaitForWritingDatabase()
+ }
refreshDynamicRefText(node, tree)
}()
return