Fix error when you upload an empty file

Fix #838
pull/862/head
Julien Duponchelle 8 years ago
parent b79235afb7
commit 60eea1f171
No known key found for this signature in database
GPG Key ID: CE8B29639E07F5E8

@ -451,6 +451,8 @@ class Compute:
elif data is not None:
if hasattr(data, '__json__'):
data = json.dumps(data.__json__())
elif isinstance(data, aiohttp.streams.EmptyStreamReader):
data = None
# Stream the request
elif isinstance(data, aiohttp.streams.StreamReader) or isinstance(data, bytes):
chunked = True

Loading…
Cancel
Save