Skip to content

Commit 761755f

Browse files
import six package and update fix
1 parent 91e49a9 commit 761755f

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

openpay/util.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,15 @@
1-
21
import logging
32
import sys
43

5-
from past.builtins import unicode
4+
import six
65

76
logger = logging.getLogger('stripe')
87

98
__all__ = ['utf8']
109

1110

1211
def utf8(value):
13-
if isinstance(value, unicode) and sys.version_info < (3, 0):
12+
if isinstance(value, six.text_type) and sys.version_info < (3, 0):
1413
return value.encode('utf-8')
1514
else:
1615
return value

0 commit comments

Comments
 (0)