fix(fs): forget cache when get link error (#956)

This commit is contained in:
Seven
2025-08-02 11:03:34 +08:00
committed by GitHub
parent 05ff7908f2
commit 58dbf088f9

View File

@@ -295,6 +295,7 @@ func Link(ctx context.Context, storage driver.Driver, path string, args model.Li
fn := func() (*model.Link, error) {
link, err := storage.Link(ctx, file, args)
if err != nil {
linkG.Forget(key)
return nil, errors.Wrapf(err, "failed get link")
}
if link.Expiration != nil {