Skip to content

Commit

Permalink
fix get and head options
Browse files Browse the repository at this point in the history
  • Loading branch information
taylorotwell committed Mar 8, 2022
1 parent e6da0b8 commit 23ff879
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Illuminate/Http/Client/PendingRequest.php
Expand Up @@ -563,7 +563,7 @@ public function dd()
*/
public function get(string $url, $query = null)
{
return $this->send('GET', $url, [
return $this->send('GET', $url, func_num_args() === 1 ? [] : [
'query' => $query,
]);
}
Expand All @@ -577,7 +577,7 @@ public function get(string $url, $query = null)
*/
public function head(string $url, $query = null)
{
return $this->send('HEAD', $url, [
return $this->send('HEAD', $url, func_num_args() === 1 ? [] : [
'query' => $query,
]);
}
Expand Down

0 comments on commit 23ff879

Please sign in to comment.