summaryrefslogtreecommitdiff
path: root/django/middleware/cache.py
diff options
context:
space:
mode:
authorAlex Gaynor <alex.gaynor@gmail.com>2013-11-02 13:12:09 -0700
committerAlex Gaynor <alex.gaynor@gmail.com>2013-11-02 13:12:09 -0700
commit7548aa8ffd46eb6e0f73730d1b2eb515ba581f95 (patch)
tree963393779f4c8c33351ea605f708f8da7d9f70bf /django/middleware/cache.py
parent65c4ac3b2434d1828cb76c9f4454fe64e81354ee (diff)
More attacking E302 violators
Diffstat (limited to 'django/middleware/cache.py')
-rw-r--r--django/middleware/cache.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/django/middleware/cache.py b/django/middleware/cache.py
index dbd5b80fb2..96c6b24034 100644
--- a/django/middleware/cache.py
+++ b/django/middleware/cache.py
@@ -112,6 +112,7 @@ class UpdateCacheMiddleware(object):
self.cache.set(cache_key, response, timeout)
return response
+
class FetchFromCacheMiddleware(object):
"""
Request-phase cache middleware that fetches a page from the cache.
@@ -154,6 +155,7 @@ class FetchFromCacheMiddleware(object):
request._cache_update_cache = False
return response
+
class CacheMiddleware(UpdateCacheMiddleware, FetchFromCacheMiddleware):
"""
Cache middleware that provides basic behavior for many simple sites.