mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
MINOR Fixed JSONDataFormatter excaping (fixes #5309, thanks briley) (from r101811)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112040 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
6f3866936d
commit
7d765fc5c6
@ -115,7 +115,7 @@ class JSONDataFormatter extends DataFormatter {
|
||||
if($item->canView()) $jsonParts[] = $this->convertDataObject($item, $fields);
|
||||
}
|
||||
$json = "{\n";
|
||||
$json .= '\"totalSize\": ';
|
||||
$json .= '"totalSize": ';
|
||||
$json .= (is_numeric($this->totalSize)) ? $this->totalSize : 'null';
|
||||
$json .= ",\n";
|
||||
$json .= "\"items\": [\n" . implode(",\n", $jsonParts) . "\n]\n";
|
||||
|
Loading…
Reference in New Issue
Block a user