Skip to content

Commit

Permalink
Don' use ob_gzhandler() if zlib.output_compression ini option is set.
Browse files Browse the repository at this point in the history
  • Loading branch information
canvural committed Jun 20, 2013
1 parent 8c2b12a commit 8e9563d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Munee/Response.php
Expand Up @@ -114,7 +114,11 @@ public function setHeaders()
public function render()
{
$content = $this->assetType->getContent();
if (! $ret = ob_gzhandler($content, PHP_OUTPUT_HANDLER_START | PHP_OUTPUT_HANDLER_END)) {

if (@ini_get('zlib.output_compression')) {
$ret = $content;
}
else if (! $ret = ob_gzhandler($content, PHP_OUTPUT_HANDLER_START | PHP_OUTPUT_HANDLER_END)) {
$ret = $content;
}

Expand Down

0 comments on commit 8e9563d

Please sign in to comment.