Skip to content

Commit

Permalink
feat: Update PendingRequest to use null coalescing operator (#618)
Browse files Browse the repository at this point in the history
Co-authored-by: Deeka Wong <8337659+huangdijia@users.noreply.github.com>
  • Loading branch information
huangdijia and huangdijia authored May 9, 2024
1 parent ae40b4c commit de0ddfd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/PendingRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ class PendingRequest
/**
* The Guzzle client instance.
*
* @var Client
* @var Client|null
*/
protected $client;

Expand Down Expand Up @@ -1440,7 +1440,7 @@ protected function requestsReusableClient()
*/
protected function getReusableClient()
{
return $this->client = $this->client ?: $this->createClient($this->buildHandlerStack());
return $this->client ??= $this->createClient($this->buildHandlerStack());
}

/**
Expand Down

0 comments on commit de0ddfd

Please sign in to comment.