Use request._decode instead of request.decode.
This commit is contained in:
parent
f38576d999
commit
efed0b415d
@ -54,7 +54,7 @@ def _check(request, function):
|
|||||||
authorization = request.headers.get("Authorization", None)
|
authorization = request.headers.get("Authorization", None)
|
||||||
if authorization:
|
if authorization:
|
||||||
challenge = authorization.lstrip("Basic").strip().encode("ascii")
|
challenge = authorization.lstrip("Basic").strip().encode("ascii")
|
||||||
plain = request.decode(base64.b64decode(challenge))
|
plain = request._decode(base64.b64decode(challenge))
|
||||||
user, password = plain.split(":")
|
user, password = plain.split(":")
|
||||||
else:
|
else:
|
||||||
user = password = None
|
user = password = None
|
||||||
|
Loading…
Reference in New Issue
Block a user