mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-08-03 12:00:12 +03:00
Fix setting post/files on the underlying request
This commit is contained in:
parent
335ba0e377
commit
6226f070f0
|
@ -295,10 +295,11 @@ class Request(object):
|
||||||
else:
|
else:
|
||||||
self._full_data = self._data
|
self._full_data = self._data
|
||||||
|
|
||||||
# copy data & files refs to the underlying request so that closable
|
# if a form media type, copy data & files refs to the underlying
|
||||||
# objects are handled appropriately.
|
# http request so that closable objects are handled appropriately.
|
||||||
self.http_request._post = self.POST
|
if is_form_media_type(self.content_type):
|
||||||
self.http_request._files = self.FILES
|
self.http_request._post = self.POST
|
||||||
|
self.http_request._files = self.FILES
|
||||||
|
|
||||||
def _load_stream(self):
|
def _load_stream(self):
|
||||||
"""
|
"""
|
||||||
|
|
Loading…
Reference in New Issue
Block a user