Skip to content

Commit 102be5e

Browse files
ruudknicolas-grekas
andcommitted
Apply suggestion from @nicolas-grekas
Co-authored-by: Nicolas Grekas <nicolas.grekas@gmail.com>
1 parent 66991e6 commit 102be5e

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/Symfony/Component/Security/Http/AccessToken/Oidc/OidcTokenHandler.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,9 +109,7 @@ public function getUserBadgeFrom(string $accessToken): UserBadge
109109
foreach ($this->discovery as ['cache' => $discoveryCache, 'client' => $discoveryClient, 'oidcConfigurationCacheKey' => $oidcConfigurationCacheKey, 'oidcJWKSetCacheKey' => $oidcJWKSetCacheKey]) {
110110
try {
111111
$oidcConfiguration = json_decode($discoveryCache->get($oidcConfigurationCacheKey, static function () use ($discoveryClient): string {
112-
$response = $discoveryClient->request('GET', '.well-known/openid-configuration');
113-
114-
return $response->getContent();
112+
return $discoveryClient->request('GET', '.well-known/openid-configuration')->getContent();
115113
}), true, 512, \JSON_THROW_ON_ERROR);
116114
} catch (\Throwable $e) {
117115
$this->logger?->error('An error occurred while requesting OIDC configuration.', [

0 commit comments

Comments
 (0)