From 9dc4ffc071725c22fc5aea9755d4ca7ea06f5de0 Mon Sep 17 00:00:00 2001 From: Jordi Boggiano Date: Mon, 11 Feb 2013 11:26:52 +0100 Subject: [PATCH] Fix json encoding in ChromePHPHandler, fixes #160 --- src/Monolog/Handler/ChromePHPHandler.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Monolog/Handler/ChromePHPHandler.php b/src/Monolog/Handler/ChromePHPHandler.php index 38196c22c..d5a910ac5 100644 --- a/src/Monolog/Handler/ChromePHPHandler.php +++ b/src/Monolog/Handler/ChromePHPHandler.php @@ -97,7 +97,8 @@ protected function send() self::$initialized = true; } - $this->sendHeader(self::HEADER_NAME, base64_encode(utf8_encode(json_encode(self::$json)))); + $json = @json_encode(self::$json); + $this->sendHeader(self::HEADER_NAME, base64_encode(utf8_encode($json))); } /**