diff options
author | Matthieu Aubry <mattab@users.noreply.github.com> | 2016-12-02 07:32:03 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-12-02 07:32:03 +0300 |
commit | 95dff7b6812f54c1afc67d6781a5d01d47c3ca60 (patch) | |
tree | 3c49147c490360c0d436dba0e1c9690d9978bd0b /plugins/API/Renderer/Json2.php | |
parent | 28409d4c92f46ce3b250501c769bb08ebb26884c (diff) | |
parent | 59ba07cba11cd51a49ba5a4946abee0d34c4c7a9 (diff) |
Merge pull request #10945 from piwik/3.x-dev3.0.0-b4
Piwik 3.0.0-b4 release
Diffstat (limited to 'plugins/API/Renderer/Json2.php')
-rw-r--r-- | plugins/API/Renderer/Json2.php | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/plugins/API/Renderer/Json2.php b/plugins/API/Renderer/Json2.php index 898fe6a9ce..bd27810fb8 100644 --- a/plugins/API/Renderer/Json2.php +++ b/plugins/API/Renderer/Json2.php @@ -11,23 +11,8 @@ namespace Piwik\Plugins\API\Renderer; use Piwik\Piwik; /** - * Correct API output renderer for JSON. Includes bug fixes for bugs in the old JSON API - * format. + * Left here for Backward compatibility in Piwik 3.X+ for all users who correctly used format=json2 during Piwik 2.X */ class Json2 extends Json { - public function renderArray($array) - { - $result = parent::renderArray($array); - - // if $array is a simple associative array, remove the JSON root array that is added by renderDataTable - if (!empty($array) - && Piwik::isAssociativeArray($array) - && !Piwik::isMultiDimensionalArray($array) - ) { - $result = substr($result, 1, strlen($result) - 2); - } - - return $result; - } }
\ No newline at end of file |