mirror of
https://github.com/httpie/cli.git
synced 2026-06-20 11:32:56 +02:00
Added tests for binary request data.
This commit is contained in:
1 parent
8905b4fc72
commit
90d34ffd0d
7 files changed
+78
-14
No files matched your search
@@ -120,6 +120,10 @@ class HTTPMessage(object):
|
||||
|
||||
# Body
|
||||
if request.files:
|
||||
# TODO: would be nice if we didn't need to encode the files again
|
||||
for fn, fd in request.files.values():
|
||||
# Rewind the files as they have already been read before.
|
||||
fd.seek(0)
|
||||
body, _ = request._encode_files(request.files)
|
||||
else:
|
||||
try:
|
||||
|
||||
Reference in new issue
Block a user