Modify: oss handle sign URL

This commit is contained in:
HFO4
2020-02-27 15:12:15 +08:00
parent bd643fa2d5
commit c4eada2723
6 changed files with 96 additions and 27 deletions

View File

@ -154,7 +154,7 @@ func (fs *FileSystem) GetUploadToken(ctx context.Context, path string, size uint
// 是否需要预先生成存储路径
var savePath string
if fs.User.Policy.IsPathGenerateNeeded() {
savePath = fs.GenerateSavePath(ctx, local.FileStream{Name: name})
savePath = fs.GenerateSavePath(ctx, local.FileStream{Name: name, VirtualPath: path})
ctx = context.WithValue(ctx, fsctx.SavePathCtx, savePath)
}
ctx = context.WithValue(ctx, fsctx.FileSizeCtx, size)