diff options
author | Adrian Holovaty <adrian@holovaty.com> | 2005-10-19 13:44:55 +0000 |
---|---|---|
committer | Adrian Holovaty <adrian@holovaty.com> | 2005-10-19 13:44:55 +0000 |
commit | ed2f2419a1a49e1cc3e1279ae922babafcd0395a (patch) | |
tree | c0a1a8b5628b2ef0bbc715eac474cac8a07302ac /django/middleware/cache.py | |
parent | d8632868f969c4913fdc1b3b2362eef6b0a69561 (diff) | |
download | django-ed2f2419a1a49e1cc3e1279ae922babafcd0395a.tar.gz |
Fixed #647 -- Fixed cache middleware not to expect _cache_update_cache, in case of 404s and 500s. Thanks, Eugene
git-svn-id: http://code.djangoproject.com/svn/django/trunk@954 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/middleware/cache.py')
-rw-r--r-- | django/middleware/cache.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/middleware/cache.py b/django/middleware/cache.py index 04f98122f7..bb3396c849 100644 --- a/django/middleware/cache.py +++ b/django/middleware/cache.py @@ -52,7 +52,7 @@ class CacheMiddleware: def process_response(self, request, response): "Sets the cache, if needed." - if not request._cache_update_cache: + if not hasattr(request, '_cache_update_cache') or not request._cache_update_cache: # We don't need to update the cache, just return. return response if not request.META['REQUEST_METHOD'] == 'GET': |