@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | */ |
50 | 50 | public function verifyScopes(ClientInterface $client, array $scopes): void |
51 | 51 | { |
52 | - if(empty($scopes)) { |
|
52 | + if (empty($scopes)) { |
|
53 | 53 | throw new OAuthException('invalid_scope', |
54 | 54 | 'The request scope is unknown.', |
55 | 55 | 'https://tools.ietf.org/html/rfc6749#section-4.1'); |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | |
58 | 58 | if ($client instanceof RegisteredClient && is_array($client->getMetadata()->getScope())) { |
59 | 59 | $supportedScopes = explode(' ', $client->getMetadata()->getScope()); |
60 | - if(!empty(array_diff($scopes, $supportedScopes))) { |
|
60 | + if (!empty(array_diff($scopes, $supportedScopes))) { |
|
61 | 61 | throw new OAuthException('invalid_scope', |
62 | 62 | 'The request scope is invalid. Supported scopes : '.$client->getMetadata()->getScope(), |
63 | 63 | 'https://tools.ietf.org/html/rfc6749#section-4.1'); |
@@ -47,7 +47,7 @@ |
||
47 | 47 | */ |
48 | 48 | $scope = $requestData['scope'] ?? ''; |
49 | 49 | $scopes = explode(' ', $scope); |
50 | - if(!in_array('openid', $scopes)) { |
|
50 | + if (!in_array('openid', $scopes)) { |
|
51 | 51 | return parent::handleRequest($request); |
52 | 52 | } |
53 | 53 |
@@ -57,7 +57,7 @@ |
||
57 | 57 | } |
58 | 58 | } else { |
59 | 59 | $codeChallengeMethod = empty($requestData['code_challenge_method']) ? 'plain' : $requestData['code_challenge_method']; |
60 | - if(!in_array($codeChallengeMethod, ['plain', 'S256'])) { |
|
60 | + if (!in_array($codeChallengeMethod, ['plain', 'S256'])) { |
|
61 | 61 | throw new OAuthException('invalid_request', |
62 | 62 | 'The request includes the invalid parameter code_challenge_method. Supported : plain, S256', |
63 | 63 | 'https://tools.ietf.org/html/rfc7636#section-4'); |