[Catalyst-commits] r11958 -
Catalyst-Plugin-Compress/trunk/lib/Catalyst/Plugin
xinming at dev.catalyst.perl.org
xinming at dev.catalyst.perl.org
Sat Nov 21 04:36:59 GMT 2009
Author: xinming
Date: 2009-11-21 04:36:59 +0000 (Sat, 21 Nov 2009)
New Revision: 11958
Modified:
Catalyst-Plugin-Compress/trunk/lib/Catalyst/Plugin/Compress.pm
Log:
Check $c->debug before calling $c->log->debug() for C::P::Compress
Modified: Catalyst-Plugin-Compress/trunk/lib/Catalyst/Plugin/Compress.pm
===================================================================
--- Catalyst-Plugin-Compress/trunk/lib/Catalyst/Plugin/Compress.pm 2009-11-21 03:08:35 UTC (rev 11957)
+++ Catalyst-Plugin-Compress/trunk/lib/Catalyst/Plugin/Compress.pm 2009-11-21 04:36:59 UTC (rev 11958)
@@ -60,9 +60,11 @@
*_do_compress = \&{"_${_method}_compress"};
}
- $_method
- ? $c->log->debug(qq{Catalyst::Plugin::Compress sets compression_format to '$_method'})
- : $c->log->debug(qq{Catalyst::Plugin::Compress has no compression_format config - disabled.});
+ if ($c->debug) {
+ $_method
+ ? $c->log->debug(qq{Catalyst::Plugin::Compress sets compression_format to '$_method'})
+ : $c->log->debug(qq{Catalyst::Plugin::Compress has no compression_format config - disabled.});
+ }
$c->maybe::next::method(@_);
}
More information about the Catalyst-commits
mailing list