Skip to content
This repository was archived by the owner on Aug 21, 2020. It is now read-only.

Commit 224f409

Browse files
Hunt Xudims
authored andcommitted
utils: fix bug when decoding
utils._decode should return an instance of 'str' instead of 'bytes' in Python 3. Fixes: #24
1 parent 8fccb67 commit 224f409

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

etcd3gw/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ def _decode(data):
3838
"""
3939
if not isinstance(data, bytes_types):
4040
data = six.b(str(data))
41-
return base64.b64decode(data.decode("utf-8"))
41+
return base64.b64decode(data).decode("utf-8")
4242

4343

4444
def _increment_last_byte(data):

0 commit comments

Comments
 (0)