mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-05-03 00:12:42 +08:00
🎨 Trim space in dialynote/block ref/new doc save path https://github.com/siyuan-note/siyuan/issues/14482
This commit is contained in:
parent
8554804ae2
commit
2a839f9086
@ -1080,6 +1080,7 @@ func CreateDailyNote(boxID string) (p string, existed bool, err error) {
|
||||
|
||||
FlushTxQueue()
|
||||
|
||||
hPath = util.TrimSpaceInPath(hPath)
|
||||
existRoot := treenode.GetBlockTreeRootByHPath(box.ID, hPath)
|
||||
if nil != existRoot {
|
||||
existed = true
|
||||
|
@ -40,6 +40,7 @@ func createDocsByHPath(boxID, hPath, content, parentID, id string) (retID string
|
||||
retID = id
|
||||
|
||||
hPath = strings.TrimSuffix(hPath, ".sy")
|
||||
hPath = util.TrimSpaceInPath(hPath)
|
||||
if "" != parentID {
|
||||
// The save path is incorrect when creating a sub-doc by ref in a doc with the same name https://github.com/siyuan-note/siyuan/issues/8138
|
||||
// 在指定了父文档 ID 的情况下优先查找父文档
|
||||
|
Loading…
Reference in New Issue
Block a user