@@ -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 getHttpClient(PendingRequest $httpClient): PendingRequest |
@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | |
55 | 55 | protected function resolveCustomAuth(PendingRequest $httpClient): PendingRequest |
56 | 56 | { |
57 | - if (! is_callable($this->customCallback)) { |
|
57 | + if (!is_callable($this->customCallback)) { |
|
58 | 58 | throw new InvalidArgumentException('customCallback must be callable'); |
59 | 59 | } |
60 | 60 |
@@ -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' => '', |
@@ -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 | |
@@ -118,7 +118,7 @@ discard block |
||
118 | 118 | return $httpClient->withToken($this->token, $options->authType); |
119 | 119 | } |
120 | 120 | if ($options->authType === self::AUTH_TYPE_BASIC) { |
121 | - if (! $this->clientId || ! $this->clientSecret) { |
|
121 | + if (!$this->clientId || !$this->clientSecret) { |
|
122 | 122 | throw new InvalidArgumentException('Basic auth requires client id and client secret. Check documentation/readme. '); |
123 | 123 | } |
124 | 124 |
@@ -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, |