mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
🐛 Assets search garbled characters Fix https://github.com/siyuan-note/siyuan/issues/8828
This commit is contained in:
parent
d8614cd594
commit
bcf0a9341b
1 changed files with 3 additions and 1 deletions
|
|
@ -68,7 +68,9 @@ func RemoveID(name string) string {
|
|||
ext := path.Ext(name)
|
||||
name = strings.TrimSuffix(name, ext)
|
||||
if 23 < len(name) {
|
||||
name = name[:len(name)-23]
|
||||
if id := name[len(name)-22:]; ast.IsNodeIDPattern(id) {
|
||||
name = name[:len(name)-23]
|
||||
}
|
||||
}
|
||||
return name + ext
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue