Skip to content

Commit fb0a434

Browse files
committed
Merge pull request #2399 from askholme/master
Fix for FileUploadParser with 3.x
2 parents 69fea56 + d6bff10 commit fb0a434

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rest_framework/parsers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ def parse(self, stream, media_type=None, parser_context=None):
277277
for index, handler in enumerate(upload_handlers):
278278
file_obj = handler.file_complete(counters[index])
279279
if file_obj:
280-
return DataAndFiles(None, {'file': file_obj})
280+
return DataAndFiles({}, {'file': file_obj})
281281
raise ParseError("FileUpload parse error - "
282282
"none of upload handlers can handle the stream")
283283

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy