Skip to content

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

:art: Improve assets rename https://github.com/siyuan-note/siyuan/issues/12497

Daniel37647191c68f
diff --git a/kernel/model/assets.go b/kernel/model/assets.go
index e69fb7c8c2..e21046a33c 100644
--- a/kernel/model/assets.go
+++ b/kernel/model/assets.go
@@ -697,7 +697,6 @@ func RenameAsset(oldPath, newName string) (newPath string, err error) {
if ocrText := util.GetAssetText(oldPath); "" != ocrText {
// 图片重命名后 ocr-texts.json 需要更新 https://github.com/siyuan-note/siyuan/issues/12974
util.SetAssetText(newPath, ocrText)
- util.RemoveAssetText(oldPath)
}
IncSync()