Body should be bytes.
This commit is contained in:
parent
f9d0116283
commit
e091d4d0aa
|
@ -38,7 +38,7 @@ class BadResponse(object):
|
|||
return ""
|
||||
|
||||
|
||||
def do_http(method, url, body=""):
|
||||
def do_http(method, url, body=b""):
|
||||
if isinstance(body, bytes):
|
||||
body = BytesIO(body)
|
||||
elif isinstance(body, six.text_type):
|
||||
|
|
Loading…
Reference in New Issue