summaryrefslogtreecommitdiff
path: root/boto/s3
diff options
context:
space:
mode:
Diffstat (limited to 'boto/s3')
-rw-r--r--boto/s3/bucket.py2
-rw-r--r--boto/s3/connection.py6
2 files changed, 4 insertions, 4 deletions
diff --git a/boto/s3/bucket.py b/boto/s3/bucket.py
index fdd040c8..e24d1a51 100644
--- a/boto/s3/bucket.py
+++ b/boto/s3/bucket.py
@@ -852,7 +852,7 @@ class Bucket(object):
if isinstance(src_key_name, bytes):
src_key_name = src_key_name.decode('utf-8')
else:
- src_key_name = boto.utils.get_utf8_value(src_key_name)
+ src_key_name = six.ensure_str(src_key_name)
if preserve_acl:
if self.name == src_bucket_name:
src_bucket = self
diff --git a/boto/s3/connection.py b/boto/s3/connection.py
index 224bf882..22b06b7d 100644
--- a/boto/s3/connection.py
+++ b/boto/s3/connection.py
@@ -88,7 +88,7 @@ class _CallingFormat(object):
return self.get_bucket_server(server, bucket)
def build_auth_path(self, bucket, key=''):
- key = boto.utils.get_utf8_value(key)
+ key = six.ensure_str(key)
if isinstance(bucket, bytes):
bucket = bucket.decode('utf-8')
path = ''
@@ -97,7 +97,7 @@ class _CallingFormat(object):
return path + '/%s' % urllib.parse.quote(key)
def build_path_base(self, bucket, key=''):
- key = boto.utils.get_utf8_value(key)
+ key = six.ensure_str(key)
return '/%s' % urllib.parse.quote(key)
@@ -121,7 +121,7 @@ class OrdinaryCallingFormat(_CallingFormat):
return server
def build_path_base(self, bucket, key=''):
- key = boto.utils.get_utf8_value(key)
+ key = six.ensure_str(key)
path_base = '/'
if bucket:
path_base += "%s/" % bucket