diff options
Diffstat (limited to 'django/utils/cache.py')
-rw-r--r-- | django/utils/cache.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/django/utils/cache.py b/django/utils/cache.py index 91c4796988..0fceaa96e6 100644 --- a/django/utils/cache.py +++ b/django/utils/cache.py @@ -95,7 +95,8 @@ def get_max_age(response): pass def _set_response_etag(response): - response['ETag'] = '"%s"' % hashlib.md5(response.content).hexdigest() + if not response.streaming: + response['ETag'] = '"%s"' % hashlib.md5(response.content).hexdigest() return response def patch_response_headers(response, cache_timeout=None): |