An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作
TypeScript agentic-aiai-agentknowledge-baselocal-firstmarkdownmcpmindmapnote-takingself-hostedsiyuanworkspace
:bug: Fix clean unused assets stat https://github.com/siyuan-note/siyuan/issues/13096
Daniel01415b482170
diff --git a/kernel/model/assets.go b/kernel/model/assets.goindex d2050f959c..ec66f97d5a 100644--- a/kernel/model/assets.go+++ b/kernel/model/assets.go@@ -525,7 +525,12 @@ func RemoveUnusedAssets() (ret []string) {if filelock.IsExist(absPath) {info, statErr := os.Stat(absPath)if statErr == nil {- size += info.Size()+ if info.IsDir() {+ dirSize, _ := util.SizeOfDirectory(absPath)+ size += dirSize+ } else {+ size += info.Size()+ }}if err := filelock.Remove(absPath); err != nil {