From 63601400e476c6cf43d985f3e7b9864681695ed4 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Fri, 18 Jan 2013 16:46:04 +0100 Subject: Update to MediaWiki 1.20.2 this update includes: * adjusted Arch Linux skin * updated FluxBBAuthPlugin * patch for https://bugzilla.wikimedia.org/show_bug.cgi?id=44024 --- includes/json/FormatJson.php | 32 ++++++++++++++++++++------------ includes/json/Services_JSON.php | 1 + 2 files changed, 21 insertions(+), 12 deletions(-) (limited to 'includes/json') diff --git a/includes/json/FormatJson.php b/includes/json/FormatJson.php index f7373e45..f67700c9 100644 --- a/includes/json/FormatJson.php +++ b/includes/json/FormatJson.php @@ -1,15 +1,26 @@ encode( $value, $isHtml ); } else { - return json_encode( $value ); + return json_encode( $value, $isHtml ? JSON_PRETTY_PRINT : 0 ); } } @@ -49,7 +57,7 @@ class FormatJson { * * @return Mixed: the value encoded in json in appropriate PHP type. * Values true, false and null (case-insensitive) are returned as true, false - * and &null; respectively. &null; is returned if the json cannot be + * and "&null;" respectively. "&null;" is returned if the json cannot be * decoded or if the encoded data is deeper than the recursion limit. */ public static function decode( $value, $assoc = false ) { diff --git a/includes/json/Services_JSON.php b/includes/json/Services_JSON.php index b2090dce..398ed6a2 100644 --- a/includes/json/Services_JSON.php +++ b/includes/json/Services_JSON.php @@ -826,6 +826,7 @@ class Services_JSON /** * @todo Ultimately, this should just call PEAR::isError() + * @return bool */ function isError($data, $code = null) { -- cgit v1.2.3-54-g00ecf