@@ -11,7 +11,7 @@ |
||
11 | 11 | { |
12 | 12 | public function boot(): void |
13 | 13 | { |
14 | - Http::macro('withRefreshToken', function ( |
|
14 | + Http::macro('withRefreshToken', function( |
|
15 | 15 | string $refreshUrl, |
16 | 16 | string|array|Credentials $credentials = [ |
17 | 17 | 'refresh_token' => '', |
@@ -42,7 +42,7 @@ |
||
42 | 42 | protected function validateOptions(): void |
43 | 43 | { |
44 | 44 | // Note: closures can't be checked at this point since we don't have access to the response objects |
45 | - Validator::make((array) $this, [ |
|
45 | + Validator::make((array)$this, [ |
|
46 | 46 | 'scopes.*' => 'string', |
47 | 47 | 'authType' => Rule::in([ |
48 | 48 | Credentials::AUTH_TYPE_BEARER, |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | |
40 | 40 | public function getExpiresIn(): int |
41 | 41 | { |
42 | - return (int) round(Carbon::now()->diffInSeconds($this->expiresAt)); |
|
42 | + return (int)round(Carbon::now()->diffInSeconds($this->expiresAt)); |
|
43 | 43 | } |
44 | 44 | |
45 | 45 | public function getTokenType(): string |
@@ -69,7 +69,7 @@ discard block |
||
69 | 69 | |
70 | 70 | protected function resolveCustomAuth(PendingRequest $httpClient): PendingRequest |
71 | 71 | { |
72 | - if (! is_callable($this->customCallback)) { |
|
72 | + if (!is_callable($this->customCallback)) { |
|
73 | 73 | throw new InvalidArgumentException('customCallback must be callable'); |
74 | 74 | } |
75 | 75 |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | protected ?string $clientId = null, |
42 | 42 | protected ?string $clientSecret = null, |
43 | 43 | ) { |
44 | - if (! empty($credentials)) { |
|
44 | + if (!empty($credentials)) { |
|
45 | 45 | $this->parseCredentialsArray($credentials); |
46 | 46 | } |
47 | 47 | |
@@ -115,7 +115,7 @@ discard block |
||
115 | 115 | } |
116 | 116 | |
117 | 117 | if ($options->authType === self::AUTH_TYPE_BASIC) { |
118 | - if (! $this->clientId || ! $this->clientSecret) { |
|
118 | + if (!$this->clientId || !$this->clientSecret) { |
|
119 | 119 | throw new InvalidArgumentException('Basic auth requires client id and client secret. Check documentation/readme.'); |
120 | 120 | } |
121 | 121 |
@@ -9,7 +9,7 @@ discard block |
||
9 | 9 | { |
10 | 10 | $uri = $response->effectiveUri(); |
11 | 11 | |
12 | - if (! $uri) { |
|
12 | + if (!$uri) { |
|
13 | 13 | return null; |
14 | 14 | } |
15 | 15 | |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | { |
21 | 21 | $queryString = parse_url($url, PHP_URL_QUERY); |
22 | 22 | |
23 | - if (! $queryString) { |
|
23 | + if (!$queryString) { |
|
24 | 24 | return null; |
25 | 25 | } |
26 | 26 | |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | { |
32 | 32 | parse_str($queryString, $output); |
33 | 33 | |
34 | - if (! isset($output[$queryKey])) { |
|
34 | + if (!isset($output[$queryKey])) { |
|
35 | 35 | return null; |
36 | 36 | } |
37 | 37 |