Skip to content

Commit 8aaccc8

Browse files
committed
Remove a Python 3.2 hack
Originally added in 3d3a75c
1 parent 670ab1f commit 8aaccc8

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

oauth2_provider/oauth2_validators.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
from __future__ import unicode_literals
22

3-
import six
43
import base64
54
import binascii
65
import logging
@@ -64,11 +63,6 @@ def _authenticate_basic_auth(self, request):
6463
except AttributeError:
6564
encoding = 'utf-8'
6665

67-
# Encode auth_string to bytes. This is needed for python3.2 compatibility
68-
# because b64decode function only supports bytes type in input.
69-
if isinstance(auth_string, six.string_types):
70-
auth_string = auth_string.encode(encoding)
71-
7266
try:
7367
b64_decoded = base64.b64decode(auth_string)
7468
except (TypeError, binascii.Error):

0 commit comments

Comments
 (0)