mirror of
https://github.com/django/django.git
synced 2025-10-30 00:56:09 +00:00
Fixed #23730 -- Moved support for SimpleCookie HIGHEST_PROTOCOL pickling to http.cookie.
This fix is necessary for Python 3.5 compatibility (refs #23763). Thanks Berker Peksag for review.
This commit is contained in:
@@ -39,7 +39,7 @@ class SimpleTemplateResponse(HttpResponse):
|
||||
rendered, and that the pickled state only includes rendered
|
||||
data, not the data used to construct the response.
|
||||
"""
|
||||
obj_dict = super(SimpleTemplateResponse, self).__getstate__()
|
||||
obj_dict = self.__dict__.copy()
|
||||
if not self._is_rendered:
|
||||
raise ContentNotRenderedError('The response content must be '
|
||||
'rendered before it can be pickled.')
|
||||
|
||||
Reference in New Issue
Block a user