vadvs (vadvs) wrote in changelog,
vadvs
vadvs
changelog

[bml] r135: LJSUP-7682: enable gzip compression for ...

Committer: vad
LJSUP-7682: enable gzip compression for BML generated data with "text/javascript" content-type.
U   trunk/lib/Apache/BML.pm
Modified: trunk/lib/Apache/BML.pm
===================================================================
--- trunk/lib/Apache/BML.pm	2010-12-20 07:37:47 UTC (rev 134)
+++ trunk/lib/Apache/BML.pm	2010-12-27 08:13:34 UTC (rev 135)
@@ -415,7 +415,7 @@
             $do_gzip = 1 if $Apache::BML::HAVE_ZLIB; # do if we could
         } else {
             ## other weighing
-            $do_gzip = 0 if $do_gzip && $content_type !~ m!^text/html!;
+            $do_gzip = 0 if $do_gzip && $content_type !~ m!^(text/html|text/javascript)!;
             $do_gzip = 0 if $do_gzip && LJ::Request->header_in("Accept-Encoding") !~ /gzip/;
             $do_gzip = 0 if $length < 500;
         }

Tags: bml, pm, vadvs
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments