We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 57f337a + 3fe954b commit 7e04e46Copy full SHA for 7e04e46
src/Http/Request.php
@@ -53,21 +53,21 @@ public function getParams()
53
*/
54
public function getQuery()
55
{
56
- $query = [];
+ $query = null;
57
58
if (isset($this->params['QUERY_STRING'])) {
59
parse_str($this->params['QUERY_STRING'], $query);
60
}
61
62
- return $query;
+ return $query ?: [];
63
64
65
/**
66
* {@inheritdoc}
67
68
public function getPost()
69
70
- $post = [];
+ $post = null;
71
72
if (isset($this->params['REQUEST_METHOD']) && isset($this->params['CONTENT_TYPE'])) {
73
$requestMethod = $this->params['REQUEST_METHOD'];
@@ -81,7 +81,7 @@ public function getPost()
81
82
83
84
- return $post;
+ return $post ?: [];
85
86
87
0 commit comments