s3 AccessURL

This commit is contained in:
withchao
2023-07-12 14:01:48 +08:00
parent 406a77d5b8
commit bdf93565a3
3 changed files with 6 additions and 6 deletions
+2 -2
View File
@@ -228,7 +228,7 @@ func (m *Minio) ListUploadedParts(ctx context.Context, uploadID string, name str
}
func (m *Minio) AccessURL(ctx context.Context, name string, expire time.Duration, opt *s3.AccessURLOption) (string, error) {
reqParams := make(url.Values)
//reqParams := make(url.Values)
//if opt != nil {
// if opt.ContentType != "" {
// reqParams.Set("Content-Type", opt.ContentType)
@@ -242,7 +242,7 @@ func (m *Minio) AccessURL(ctx context.Context, name string, expire time.Duration
} else if expire < time.Second {
expire = time.Second
}
u, err := m.core.Client.PresignedGetObject(ctx, m.bucket, name, expire, reqParams)
u, err := m.core.Client.PresignedGetObject(ctx, m.bucket, name, expire, nil)
if err != nil {
return "", err
}