Skip to content

Commit

Permalink
Merge pull request #18 from pich/patch-1
Browse files Browse the repository at this point in the history
Improved handling of null types.
  • Loading branch information
calcinai authored Jul 5, 2022
2 parents 397aa4a + f617b41 commit 157bcdc
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Provider/Xero.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ public function getBaseAccessTokenUrl(array $params)
}

/**
* @param array $params
* @param null|array $params
* @return string
*/
public function getTenantsUrl(array $params = null)
public function getTenantsUrl(?array $params = null)
{
if ($params) {
$params = '?' . http_build_query($params);
Expand All @@ -55,12 +55,12 @@ public function getTenantsUrl(array $params = null)

/**
* @param AccessTokenInterface $token
* @param array $params
* @param null|array $params
* @return XeroTenant[]
* @throws \League\OAuth2\Client\Provider\Exception\IdentityProviderException
* @throws \Exception
*/
public function getTenants(AccessTokenInterface $token, array $params = null)
public function getTenants(AccessTokenInterface $token, ?array $params = null)
{
$request = $this->getAuthenticatedRequest(
self::METHOD_GET,
Expand Down

0 comments on commit 157bcdc

Please sign in to comment.