From: Chad Horohoe Date: Wed, 11 Aug 2010 12:45:59 +0000 (+0000) Subject: Revert r70874: Dude that just looks kinda ugly X-Git-Tag: 1.31.0-rc.0~35551 X-Git-Url: http://git.cyclocoop.org/%24href?a=commitdiff_plain;h=50fe92ffb8eaab3a51834af68bb69df0d1bd2832;p=lhc%2Fweb%2Fwiklou.git Revert r70874: Dude that just looks kinda ugly --- diff --git a/includes/json/FormatJson.php b/includes/json/FormatJson.php index f33bc6235b..ee9d80083a 100644 --- a/includes/json/FormatJson.php +++ b/includes/json/FormatJson.php @@ -1,24 +1,12 @@ - */ public static function encode( $value, $isHtml = false ) { // Some versions of PHP have a broken json_encode, see PHP bug // 46944. Test encoding an affected character (U+20000) to @@ -31,13 +19,7 @@ class FormatJson { } } - /** - * Decode some JSON into an array or object - * @param $value String of Json - * @param $assoc bool One of AS_OBJECT or AS_ARRAY to specify return type - * @return Array or Object - */ - public static function decode( $value, $assoc = false ) { + public static function decode( $value, $assoc = self::AS_ARRAY ) { if ( !function_exists( 'json_decode' ) ) { $json = new Services_JSON(); $jsonDec = $json->decode( $value );