1
0
mirror of https://github.com/django/django.git synced 2025-10-26 15:16:09 +00:00

Fixed #13008 -- Added more Cache-Control headers to never_cache() decorator.

This commit is contained in:
Markus Bertheau
2015-04-27 23:56:02 +02:00
committed by Tim Graham
parent 82162b4499
commit 4a438e400b
7 changed files with 45 additions and 3 deletions

View File

@@ -134,6 +134,7 @@ def add_never_cache_headers(response):
Adds headers to a response to indicate that a page should never be cached.
"""
patch_response_headers(response, cache_timeout=-1)
patch_cache_control(response, no_cache=True, no_store=True, must_revalidate=True)
def patch_vary_headers(response, newheaders):