Revert "fix(fs): update objs cache" (close #511)

Revert "fix(fs): update objs cache (#507)"

This reverts commit f26892ac3c.
This commit is contained in:
j2rong4cn
2025-07-01 20:33:44 +08:00
committed by GitHub
parent f26892ac3c
commit b4997e7a7e

View File

@ -573,12 +573,8 @@ func Put(ctx context.Context, storage driver.Driver, dstDirPath string, file mod
}
case driver.Put:
err = s.Put(ctx, parentDir, file, up)
if err == nil {
if !utils.IsBool(lazyCache...) {
ClearCache(storage, dstDirPath)
} else {
addCacheObj(storage, dstDirPath, model.WrapObjName(file))
}
if err == nil && !utils.IsBool(lazyCache...) {
ClearCache(storage, dstDirPath)
}
default:
return errs.NotImplement