Skip to content

Commit acdfb12

Browse files
authored
Merge pull request #51 from dt3310321/s3
S3
2 parents 8e154db + 8697ae0 commit acdfb12

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

qcloud_cos/cos_client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ def __init__(self, Appid=None, Region=None, Secret_id=None, Secret_key=None, Tok
4646
self._timeout = Timeout
4747

4848
if Scheme is None:
49-
Scheme = u'http'
49+
Scheme = u'https'
5050
Scheme = to_unicode(Scheme)
5151
if(Scheme != u'http' and Scheme != u'https'):
5252
raise CosClientError('Scheme can be only set to http/https')
@@ -306,7 +306,7 @@ def get_presigned_download_url(self, Bucket, Key, Expired=300):
306306
)
307307
"""
308308
url = self._conf.uri(bucket=Bucket, path=Key)
309-
sign = self.get_auth(Method='GET', Bucket=Bucket, Key=Key, Expired=300)
309+
sign = self.get_auth(Method='GET', Bucket=Bucket, Key=Key, Expired=Expired)
310310
url = url + '?sign=' + quote(sign)
311311
return url
312312

0 commit comments

Comments
 (0)