merged branch genexp/master (PR #8477)
This PR was submitted for the master branch but it was merged into the 2.2 branch instead (closes #8477). Discussion ---------- Reverts recent change that added type coercion for JSON responses We shouldn't be coercing primitive in the array provided to setData. Commits ------- 02e6aef Reverts JSON_NUMERIC_CHECK
This commit is contained in:
commit
d3f16d0ea0
@ -83,7 +83,7 @@ class JsonResponse extends Response
|
|||||||
public function setData($data = array())
|
public function setData($data = array())
|
||||||
{
|
{
|
||||||
// Encode <, >, ', &, and " for RFC4627-compliant JSON, which may also be embedded into HTML.
|
// Encode <, >, ', &, and " for RFC4627-compliant JSON, which may also be embedded into HTML.
|
||||||
$this->data = json_encode($data, JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_AMP | JSON_HEX_QUOT | JSON_NUMERIC_CHECK);
|
$this->data = json_encode($data, JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_AMP | JSON_HEX_QUOT );
|
||||||
|
|
||||||
return $this->update();
|
return $this->update();
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user