🎨 兼容文件同步和快照同步

This commit is contained in:
Liang Ding 2022-07-01 15:38:05 +08:00
parent 2065aeded9
commit 5f6e416f5a
No known key found for this signature in database
GPG key ID: 136F30F901A2231D

View file

@ -447,6 +447,9 @@ func incReindex(upserts, removes []string) {
}
upsertFile = filepath.ToSlash(upsertFile)
if strings.HasPrefix(upsertFile, "/") {
upsertFile = upsertFile[1:]
}
box := upsertFile[:strings.Index(upsertFile, "/")]
p := strings.TrimPrefix(upsertFile, box)
tree, err0 := LoadTree(box, p)