- Bugfix for json_encode() which do not result in an array
This commit is contained in:
parent
ff4ade51fb
commit
ef5da7bb7e
@ -58,7 +58,7 @@ namespace Dump {
|
||||
}
|
||||
|
||||
if (isset($dump)) {
|
||||
$json = json_encode(array_merge(["_dump" => $dump ], json_decode($body->getContents() ?? "{}", true)), JsonResponse::DEFAULT_JSON_FLAGS);
|
||||
$json = json_encode(array_merge(["_dump" => $dump ], (array) json_decode($body->getContents() ?? "{}", true)), JsonResponse::DEFAULT_JSON_FLAGS);
|
||||
|
||||
$stream->write(! is_string($json) ? json_encode($json, JsonResponse::DEFAULT_JSON_FLAGS) : $json);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user