diff --git a/django/django/middleware/gzip.py b/django/django/middleware/gzip.py
index 3b84980..47f75aa 100644
a
|
b
|
class GZipMiddleware(object):
|
22 | 22 | if response.has_header('Content-Encoding'): |
23 | 23 | return response |
24 | 24 | |
25 | | # Older versions of IE have issues with gzipped pages containing either |
26 | | # Javascript and PDF. |
| 25 | # MSIE have issues with gzipped respones of various content types. |
27 | 26 | if "msie" in request.META.get('HTTP_USER_AGENT', '').lower(): |
28 | 27 | ctype = response.get('Content-Type', '').lower() |
29 | | if "javascript" in ctype or ctype == "application/pdf": |
| 28 | if not ctype.startswith("text/") or "javascript" in ctype: |
30 | 29 | return response |
31 | 30 | |
32 | 31 | ae = request.META.get('HTTP_ACCEPT_ENCODING', '') |