mirror of
https://github.com/flarum/framework.git
synced 2025-01-06 10:33:46 +08:00
Fix responses returned by JSON helper.
This commit is contained in:
parent
83a5ba5001
commit
00699b69da
|
@ -43,7 +43,10 @@ abstract class JsonApiAction implements ActionInterface
|
||||||
|
|
||||||
$data = json_encode($data, JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_AMP | JSON_HEX_QUOT);
|
$data = json_encode($data, JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_AMP | JSON_HEX_QUOT);
|
||||||
|
|
||||||
return new Response($data, $status);
|
$response = new Response('php://memory', $status);
|
||||||
|
$response->getBody()->write($data);
|
||||||
|
|
||||||
|
return $response;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue
Block a user