Skip to content

Commit

Permalink
Handle unicode strings for base64 decoding
Browse files Browse the repository at this point in the history
  • Loading branch information
jbowes committed Apr 19, 2017
1 parent a8f76cd commit 18f1f24
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion manifoldco_signature/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ def _decode_base64(data):
missing_padding = len(data) % 4
if missing_padding != 0:
data += '='* (4 - missing_padding)
return base64.urlsafe_b64decode(data)
return base64.urlsafe_b64decode(str(data))

from ._version import get_versions
__version__ = get_versions()['version']
Expand Down
1 change: 1 addition & 0 deletions tests/test_manifoldco_signature.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from builtins import bytes

import pytest
Expand Down

0 comments on commit 18f1f24

Please sign in to comment.