fix(alias): check obj exist for every storage (fix d9795ff)

pull/3852/head
Andy Hsu 2023-03-14 20:11:25 +08:00
parent d9795ff22f
commit b8bc94306d
1 changed files with 4 additions and 0 deletions

View File

@ -84,6 +84,10 @@ func (d *Alias) link(ctx context.Context, dst, sub string, args model.LinkArgs)
if err != nil {
return nil, err
}
_, err = fs.Get(ctx, reqPath)
if err != nil {
return nil, err
}
if common.ShouldProxy(storage, stdpath.Base(sub)) {
return &model.Link{
URL: fmt.Sprintf("/p%s?sign=%s",