mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-16 01:24:38 +00:00
(mvc) add some basic sanitization to api output
This commit is contained in:
parent
a004fe9ac7
commit
02ca80d843
@ -90,7 +90,7 @@ class ApiControllerBase extends ControllerRoot
|
||||
$data = $dispatcher->getReturnedValue();
|
||||
if (is_array($data)) {
|
||||
$this->response->setContentType('application/json', 'UTF-8');
|
||||
echo json_encode($data) ;
|
||||
echo htmlspecialchars(json_encode($data), ENT_NOQUOTES);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user