🎨 Improve data indexing performance when importing .sy.zip and markdown https://github.com/siyuan-note/siyuan/issues/10986

This commit is contained in:
Daniel 2024-04-11 21:54:34 +08:00
parent 2bcf26166d
commit f5ceb847f4
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
15 changed files with 45 additions and 33 deletions

View file

@ -235,7 +235,7 @@ func NetImg2LocalAssets(rootID, originalURL string) (err error) {
})
if 0 < files {
util.PushUpdateMsg(msgId, Conf.Language(113), 7000)
if err = writeJSONQueue(tree); nil != err {
if err = writeTreeUpsertQueue(tree); nil != err {
return
}
util.PushUpdateMsg(msgId, fmt.Sprintf(Conf.Language(120), files), 5000)
@ -422,7 +422,7 @@ func NetAssets2LocalAssets(rootID string) (err error) {
if 0 < files {
util.PushUpdateMsg(msgId, Conf.Language(113), 7000)
if err = writeJSONQueue(tree); nil != err {
if err = writeTreeUpsertQueue(tree); nil != err {
return
}
util.PushUpdateMsg(msgId, fmt.Sprintf(Conf.Language(120), files), 5000)