1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

Fixed #26014 -- Added WSGIRequest content_type and content_params attributes.

Parsed the CONTENT_TYPE header once and recorded it on the request.
This commit is contained in:
Curtis Maloney
2015-08-07 15:51:39 +10:00
committed by Tim Graham
parent dca8b916ff
commit 6f1318734f
5 changed files with 42 additions and 8 deletions

View File

@@ -299,6 +299,11 @@ Requests and Responses
:meth:`~django.http.HttpResponse.seekable()` to make an instance a
stream-like object and allow wrapping it with :py:class:`io.TextIOWrapper`.
* Added the :attr:`HttpResponse.content_type
<django.http.HttpRequest.content_type>` and
:attr:`~django.http.HttpRequest.content_params` attributes which are
parsed from the ``CONTENT_TYPE`` header.
Serialization
~~~~~~~~~~~~~