Skip to content

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

:art: `Convert network images to local` supports URL-encoded local file names https://github.com/siyuan-note/siyuan/issues/9929

Daniel6e0524b23544
diff --git a/kernel/model/assets.go b/kernel/model/assets.go
index 85f66aac91..71c9c7d126 100644
--- a/kernel/model/assets.go
+++ b/kernel/model/assets.go
@@ -111,6 +111,10 @@ func NetImg2LocalAssets(rootID, originalURL string) (err error) {
// `网络图片转换为本地图片` 支持处理 `file://` 本地路径图片 https://github.com/siyuan-note/siyuan/issues/6546
u := string(dest)[7:]
+ unescaped, _ := url.PathUnescape(u)
+ if unescaped != u {
+ u = unescaped
+ }
if !gulu.File.IsExist(u) || gulu.File.IsDir(u) {
return ast.WalkSkipChildren
}