🎨 Automatic refresh of document tree information https://github.com/siyuan-note/siyuan/issues/11043

This commit is contained in:
Daniel 2024-09-28 23:41:25 +08:00
parent 63ae805106
commit 8edd56b371
No known key found for this signature in database
GPG key ID: 86211BA83DF03017

View file

@ -47,12 +47,11 @@ func refreshParentDocInfo(tree *parse.Tree) {
luteEngine := lute.New()
boxDir := filepath.Join(util.DataDir, tree.Box)
parentDir := path.Dir(tree.Path)
parentPath := parentDir + ".sy"
if parentDir == boxDir || parentDir == "/" {
return
}
parentPath := parentDir + ".sy"
parentTree, err := filesys.LoadTree(tree.Box, parentPath, luteEngine)
if err != nil {
return