@@ -39,7 +39,7 @@ |
||
| 39 | 39 | $authRequest = $request->getAttribute(AuthRequestInterface::class); |
| 40 | 40 | $authSession = $request->getAttribute(AuthSessionInterface::class); |
| 41 | 41 | |
| 42 | - if (! $authRequest instanceof AuthRequestInterface) { |
|
| 42 | + if (!$authRequest instanceof AuthRequestInterface) { |
|
| 43 | 43 | throw new RuntimeException('Unable to find a valid attribute for ' . AuthRequestInterface::class); |
| 44 | 44 | } |
| 45 | 45 | |
@@ -47,7 +47,7 @@ |
||
| 47 | 47 | |
| 48 | 48 | $code = $claims['code'] ?? null; |
| 49 | 49 | |
| 50 | - if (! $code) { |
|
| 50 | + if (!$code) { |
|
| 51 | 51 | throw new RuntimeException('Unable to find a code claim to make a token request'); |
| 52 | 52 | } |
| 53 | 53 | |
@@ -19,13 +19,13 @@ |
||
| 19 | 19 | { |
| 20 | 20 | $authResponse = $request->getAttribute(AuthResponseInterface::class); |
| 21 | 21 | |
| 22 | - if (! $authResponse instanceof AuthResponseInterface) { |
|
| 22 | + if (!$authResponse instanceof AuthResponseInterface) { |
|
| 23 | 23 | throw new RuntimeException('Unable to find a valid attribute for ' . AuthResponseInterface::class); |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | $authSession = $request->getAttribute(AuthSessionInterface::class); |
| 27 | 27 | |
| 28 | - if (! $authSession instanceof AuthSessionInterface) { |
|
| 28 | + if (!$authSession instanceof AuthSessionInterface) { |
|
| 29 | 29 | throw new RuntimeException('Unable to find a valid attribute for ' . AuthSessionInterface::class); |
| 30 | 30 | } |
| 31 | 31 | |
@@ -51,7 +51,7 @@ |
||
| 51 | 51 | $cookieValue = $sessionCookie ? $sessionCookie->getValue() : null; |
| 52 | 52 | $data = $cookieValue ? \json_decode($cookieValue, true) : []; |
| 53 | 53 | |
| 54 | - if (! \is_array($data)) { |
|
| 54 | + if (!\is_array($data)) { |
|
| 55 | 55 | $data = []; |
| 56 | 56 | } |
| 57 | 57 | |
@@ -39,13 +39,13 @@ |
||
| 39 | 39 | { |
| 40 | 40 | $tokenResponse = $request->getAttribute(TokenResponseInterface::class); |
| 41 | 41 | |
| 42 | - if (! $tokenResponse instanceof TokenResponseInterface) { |
|
| 42 | + if (!$tokenResponse instanceof TokenResponseInterface) { |
|
| 43 | 43 | throw new RuntimeException('Unable to get token response attribute'); |
| 44 | 44 | } |
| 45 | 45 | |
| 46 | 46 | $accessToken = $tokenResponse->getAccessToken(); |
| 47 | 47 | |
| 48 | - if (! $accessToken) { |
|
| 48 | + if (!$accessToken) { |
|
| 49 | 49 | throw new RuntimeException(sprintf( |
| 50 | 50 | 'Unable to get access token from "%s" attribute', |
| 51 | 51 | TokenResponseInterface::class |
@@ -46,13 +46,13 @@ |
||
| 46 | 46 | { |
| 47 | 47 | $authResponse = $request->getAttribute(AuthResponseInterface::class); |
| 48 | 48 | |
| 49 | - if (! $authResponse instanceof AuthResponseInterface) { |
|
| 49 | + if (!$authResponse instanceof AuthResponseInterface) { |
|
| 50 | 50 | throw new RuntimeException('Unable to get auth token response attribute'); |
| 51 | 51 | } |
| 52 | 52 | |
| 53 | 53 | $code = $authResponse->getCode(); |
| 54 | 54 | |
| 55 | - if (! $code) { |
|
| 55 | + if (!$code) { |
|
| 56 | 56 | throw new RuntimeException('Unable to get auth code'); |
| 57 | 57 | } |
| 58 | 58 | |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | { |
| 20 | 20 | $data = \json_decode($request->getBody()->getContents(), true); |
| 21 | 21 | |
| 22 | - if (! \is_array($data)) { |
|
| 22 | + if (!\is_array($data)) { |
|
| 23 | 23 | throw new RuntimeException('Unable to decode response body'); |
| 24 | 24 | } |
| 25 | 25 | |
@@ -37,7 +37,7 @@ |
||
| 37 | 37 | |
| 38 | 38 | public function create(string $responseMode): ResponseModeInterface |
| 39 | 39 | { |
| 40 | - if (! \array_key_exists($responseMode, $this->modes)) { |
|
| 40 | + if (!\array_key_exists($responseMode, $this->modes)) { |
|
| 41 | 41 | throw new InvalidArgumentException('Unsupported response mode "' . $responseMode . '"'); |
| 42 | 42 | } |
| 43 | 43 | |
@@ -40,7 +40,7 @@ |
||
| 40 | 40 | /** @var string|null $token */ |
| 41 | 41 | $token = $baseParams['response'] ?? null; |
| 42 | 42 | |
| 43 | - if (! $token) { |
|
| 43 | + if (!$token) { |
|
| 44 | 44 | throw new InvalidArgumentException('Invalid authorization request from provider, no "response" parameter'); |
| 45 | 45 | } |
| 46 | 46 | |