We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6cb1210 commit b7ef6d9Copy full SHA for b7ef6d9
1 file changed
src/Net/Http/Server/Connection.php
@@ -521,7 +521,7 @@ private function parseRequestBody(): void
521
{
522
if ($this->method->value === 'POST') {
523
if (str_contains($this->contentType, 'application/json')) {
524
- $this->post = array_merge($this->post, json_decode($this->content, true) ?? []);
+ $this->post = array_merge($this->post, json_decode($this->content ?? '', true) ?? []);
525
} elseif ($this->contentType === 'application/x-www-form-urlencoded') {
526
parse_str($this->content, $this->post);
527
}
0 commit comments