Skip to content

Commit c0d74c6

Browse files
authored
Merge pull request #14 from marcriemer/analysis-kYbjYy
Apply fixes from StyleCI
2 parents 58cbe2a + 9113224 commit c0d74c6

File tree

7 files changed

+9
-17
lines changed

7 files changed

+9
-17
lines changed

src/ClaimExtractor.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@ public function __construct(array $claimSets = [])
5555
}
5656

5757
/**
58-
*
5958
* @return $this
6059
*
6160
* @throws \InvalidArgumentException

src/ClaimExtractorInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ interface ClaimExtractorInterface
1212
* For given scopes and aggregated claims get all claims that have been configured on the extractor.
1313
*
1414
* @param array<int, ScopeEntityInterface> $scopes
15-
* @param array<string, string> $claims
15+
* @param array<string, string> $claims
1616
*
1717
* @return array<string, string>
1818
*/

src/Entities/ClaimSetEntry.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ class ClaimSetEntry implements ClaimSetEntryInterface
1616
/**
1717
* Summary of __construct
1818
*
19-
* @param string $scope Scope of the claimset
19+
* @param string $scope Scope of the claimset
2020
* @param string[] $claims The claims
2121
*/
2222
public function __construct(

src/IdTokenClaimsCreatedEvent.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ final class IdTokenClaimsCreatedEvent extends IdTokenEvent
1717
{
1818
/**
1919
* Builder
20-
*
2120
*/
2221
private Builder $builder;
2322

src/IdTokenIssuedEvent.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,11 @@ final class IdTokenIssuedEvent extends IdTokenEvent
1515
{
1616
/**
1717
* Token
18-
*
1918
*/
2019
private Token $token;
2120

2221
/**
2322
* Get Token
24-
*
2523
*/
2624
public function getToken(): Token
2725
{

src/ResponseTypes/IdTokenResponse.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,19 +33,16 @@ class IdTokenResponse extends BearerTokenResponse
3333

3434
/**
3535
* IdTokenRepositoryInterface
36-
*
3736
*/
3837
protected IdTokenRepositoryInterface $idTokenRepository;
3938

4039
/**
4140
* ClaimSetRepositoryInterface
42-
*
4341
*/
4442
protected ClaimSetRepositoryInterface $claimRepository;
4543

4644
/**
4745
* ClaimExtractorInterface
48-
*
4946
*/
5047
protected ClaimExtractorInterface $extractor;
5148

@@ -111,7 +108,6 @@ protected function getExtraParams(AccessTokenEntityInterface $accessToken): arra
111108
* Return true If this is an OpenID request
112109
*
113110
* @param ScopeEntityInterface[] $scopes
114-
*
115111
*/
116112
private static function isOpenIDRequest(array $scopes): bool
117113
{

tests/ResponseTypes/BearerResponseTypeTest.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -326,9 +326,9 @@ public function getClaimSetEntry(AccessTokenEntityInterface $accessToken): Claim
326326
public string $scope = 'openid';
327327

328328
/**
329-
* @var array<string, string> $claims
329+
* @var array<string, string>
330330
*/
331-
public array $claims = ["acr" => "pop"];
331+
public array $claims = ['acr' => 'pop'];
332332

333333
public function getScope(): string
334334
{
@@ -348,15 +348,15 @@ public function getClaims(): array
348348
}
349349
};
350350

351-
$IdTokenRepository = (new class () implements IdTokenRepositoryInterface{
351+
$IdTokenRepository = (new class () implements IdTokenRepositoryInterface {
352352
public function getBuilder(AccessTokenEntityInterface $accessToken): Builder
353353
{
354354
$builder = (new TokenBuilder(
355355
new JoseEncoder(),
356356
ChainedFormatter::withUnixTimestampDates()
357357
))
358358
->permittedFor($accessToken->getClient()->getIdentifier())
359-
->issuedBy("https://example.com")
359+
->issuedBy('https://example.com')
360360
->issuedAt(new DateTimeImmutable())
361361
->expiresAt($accessToken->getExpiryDateTime())
362362
->relatedTo($accessToken->getUserIdentifier())
@@ -420,7 +420,7 @@ public function getBuilder(AccessTokenEntityInterface $accessToken): Builder
420420
$json = json_decode($response->getBody()->getContents());
421421
$this->assertEquals('Bearer', $json->token_type);
422422

423-
foreach (['expires_in', "access_token", "refresh_token", "id_token"] as $claim) {
423+
foreach (['expires_in', 'access_token', 'refresh_token', 'id_token'] as $claim) {
424424
self::assertTrue(property_exists($json, $claim));
425425
}
426426

@@ -435,7 +435,7 @@ public function getBuilder(AccessTokenEntityInterface $accessToken): Builder
435435

436436
$this->assertTrue($validator->validate(
437437
$token,
438-
new IssuedBy("https://example.com")
438+
new IssuedBy('https://example.com')
439439
));
440440

441441
$this->assertTrue($validator->validate(
@@ -453,7 +453,7 @@ public function getBuilder(AccessTokenEntityInterface $accessToken): Builder
453453
new LooseValidAt(new SystemClock($accessToken->getExpiryDateTime()->getTimezone()))
454454
));
455455

456-
$this->assertTrue($validator->validate($token, new HasClaimWithValue("acr", "pop")));
456+
$this->assertTrue($validator->validate($token, new HasClaimWithValue('acr', 'pop')));
457457
$this->assertTrue($validator->validate($token, new HasClaimWithValue('nonce', 's6G31Kolwu9p')));
458458
}
459459
}

0 commit comments

Comments
 (0)