Skip to content

Commit cd6be3e

Browse files
committed
Remove unnecessary explicit type definition in constant declarations
In adhering to recommended coding practices and improving code readability, the explicit type definition in constant declarations has been removed across various files. This revision was geared towards enhancing simplicity and maintainability, without sacrificing the core functionality of the defined constants.
1 parent da529a3 commit cd6be3e

24 files changed

+46
-46
lines changed

rector.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
return static function (RectorConfig $config): void {
1515
$config->import(SetList::DEAD_CODE);
16-
$config->import(LevelSetList::UP_TO_PHP_83);
16+
$config->import(LevelSetList::UP_TO_PHP_82);
1717
$config->import(SymfonySetList::SYMFONY_64);
1818
$config->import(SymfonySetList::SYMFONY_50_TYPES);
1919
$config->import(SymfonySetList::SYMFONY_52_VALIDATOR_ATTRIBUTES);
@@ -38,7 +38,7 @@
3838
__DIR__ . '/src/Bundle/JoseFramework/DependencyInjection/Source/KeyManagement/JWKSource.php',
3939
__DIR__ . '/src/Bundle/JoseFramework/DependencyInjection/Source/KeyManagement/JWKSetSource.php',
4040
]);
41-
$config->phpVersion(PhpVersion::PHP_83);
41+
$config->phpVersion(PhpVersion::PHP_82);
4242
$config->parallel();
4343
$config->importNames();
4444
$config->importShortClasses();

src/Bundle/Helper/ConfigurationHelper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
final readonly class ConfigurationHelper
1111
{
12-
final public const string BUNDLE_ALIAS = 'jose';
12+
final public const BUNDLE_ALIAS = 'jose';
1313

1414
/**
1515
* @param string[] $signatureAlgorithms

src/Experimental/Signature/Blake2b.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
*/
2121
final readonly class Blake2b implements MacAlgorithm
2222
{
23-
private const int MINIMUM_KEY_LENGTH = 32;
23+
private const MINIMUM_KEY_LENGTH = 32;
2424

2525
public function __construct()
2626
{

src/Library/Checker/AlgorithmChecker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616
final readonly class AlgorithmChecker implements HeaderChecker
1717
{
18-
private const string HEADER_NAME = 'alg';
18+
private const HEADER_NAME = 'alg';
1919

2020
/**
2121
* @param string[] $supportedAlgorithms

src/Library/Checker/AudienceChecker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
*/
1515
final readonly class AudienceChecker implements ClaimChecker, HeaderChecker
1616
{
17-
private const string CLAIM_NAME = 'aud';
17+
private const CLAIM_NAME = 'aud';
1818

1919
public function __construct(
2020
private string $audience,

src/Library/Checker/ExpirationTimeChecker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
*/
1717
final readonly class ExpirationTimeChecker implements ClaimChecker, HeaderChecker
1818
{
19-
private const string NAME = 'exp';
19+
private const NAME = 'exp';
2020

2121
public function __construct(
2222
private ClockInterface $clock,

src/Library/Checker/IssuedAtChecker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
*/
1515
final readonly class IssuedAtChecker implements ClaimChecker, HeaderChecker
1616
{
17-
private const string NAME = 'iat';
17+
private const NAME = 'iat';
1818

1919
public function __construct(
2020
private ClockInterface $clock,

src/Library/Checker/IssuerChecker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616
final readonly class IssuerChecker implements ClaimChecker, HeaderChecker
1717
{
18-
private const string CLAIM_NAME = 'iss';
18+
private const CLAIM_NAME = 'iss';
1919

2020
public function __construct(
2121
private array $issuers,

src/Library/Checker/NotBeforeChecker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
*/
1515
final readonly class NotBeforeChecker implements ClaimChecker, HeaderChecker
1616
{
17-
private const string NAME = 'nbf';
17+
private const NAME = 'nbf';
1818

1919
public function __construct(
2020
private ClockInterface $clock,

src/Library/Checker/UnencodedPayloadChecker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
*/
1515
final class UnencodedPayloadChecker implements HeaderChecker
1616
{
17-
private const string HEADER_NAME = 'b64';
17+
private const HEADER_NAME = 'b64';
1818

1919
#[Override]
2020
public function checkHeader(mixed $value): void

0 commit comments

Comments
 (0)