Don't send the compressed version of the cache to a browser that won't take it when...
authorBrion Vibber <brion@users.mediawiki.org>
Mon, 9 Jun 2003 19:16:38 +0000 (19:16 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Mon, 9 Jun 2003 19:16:38 +0000 (19:16 +0000)
includes/Article.php

index 078dc8b..85617c3 100644 (file)
@@ -1667,9 +1667,11 @@ name=\"wpSummary\" maxlength=200 size=60><br>
                                } else {
                                        wfDebug("  failed to write gzip, still sending\n" );
                                }
-                               header( "Content-Encoding: gzip" );
-                               header( "Vary: Accept-Encoding" );
-                               return $gzout;
+                               if(wfClientAcceptsGzip()) {
+                                       header( "Content-Encoding: gzip" );
+                                       header( "Vary: Accept-Encoding" );
+                                       return $gzout;
+                               }
                        }
                }
                return $text;