diff --git a/src/Saml/ResponseContext.php b/src/Saml/ResponseContext.php index ab29d0b..cbbcd5c 100644 --- a/src/Saml/ResponseContext.php +++ b/src/Saml/ResponseContext.php @@ -28,9 +28,9 @@ final class ResponseContext implements ResponseContextInterface { public function __construct( - private IdentityProvider $hostedIdentityProvider, - private ServiceProviderRepository $serviceProviderRepository, - private StateHandlerInterface $stateHandler + private readonly IdentityProvider $hostedIdentityProvider, + private readonly ServiceProviderRepository $serviceProviderRepository, + private readonly StateHandlerInterface $stateHandler ) { } diff --git a/src/Service/DateTime/StaticDateTimeService.php b/src/Service/DateTime/StaticDateTimeService.php index 597b8ec..5b8e49c 100644 --- a/src/Service/DateTime/StaticDateTimeService.php +++ b/src/Service/DateTime/StaticDateTimeService.php @@ -25,11 +25,12 @@ final class StaticDateTimeService extends AbstractDateTimeService { - public function __construct(private readonly DateTimeImmutable $dateTime) - { + public function __construct( + private readonly DateTimeImmutable $dateTime + ) { } - public function getCurrent(): \DateTimeImmutable + public function getCurrent(): DateTimeImmutable { return $this->dateTime; } diff --git a/src/Service/ResponseService.php b/src/Service/ResponseService.php index faa5ff3..9104cd8 100644 --- a/src/Service/ResponseService.php +++ b/src/Service/ResponseService.php @@ -35,10 +35,10 @@ final class ResponseService implements ResponseServiceInterface { public function __construct( - private IdentityProvider $hostedIdentityProvider, - private ResponseContextInterface $responseContext, - private AssertionSigningServiceInterface $assertionSigningService, - private DateTimeService $dateTimeService + private readonly IdentityProvider $hostedIdentityProvider, + private readonly ResponseContextInterface $responseContext, + private readonly AssertionSigningServiceInterface $assertionSigningService, + private readonly DateTimeService $dateTimeService ) { } diff --git a/src/Service/StateBasedAuthenticationService.php b/src/Service/StateBasedAuthenticationService.php index 1a4e90c..d81c05b 100644 --- a/src/Service/StateBasedAuthenticationService.php +++ b/src/Service/StateBasedAuthenticationService.php @@ -35,9 +35,9 @@ final class StateBasedAuthenticationService implements AuthenticationService { public function __construct( - private StateHandlerInterface $stateHandler, - private RouterInterface $router, - private LoggerInterface $logger + private readonly StateHandlerInterface $stateHandler, + private readonly RouterInterface $router, + private readonly LoggerInterface $logger ) { } diff --git a/src/Service/StateBasedRegistrationService.php b/src/Service/StateBasedRegistrationService.php index d7eeeaf..cfa37fc 100644 --- a/src/Service/StateBasedRegistrationService.php +++ b/src/Service/StateBasedRegistrationService.php @@ -34,9 +34,9 @@ final class StateBasedRegistrationService implements RegistrationService { public function __construct( - private StateHandlerInterface $stateHandler, - private RouterInterface $router, - private LoggerInterface $logger + private readonly StateHandlerInterface $stateHandler, + private readonly RouterInterface $router, + private readonly LoggerInterface $logger ) { } diff --git a/src/Service/StateHandler.php b/src/Service/StateHandler.php index 1c3b35d..5f3ca96 100644 --- a/src/Service/StateHandler.php +++ b/src/Service/StateHandler.php @@ -25,8 +25,6 @@ use Surfnet\SamlBundle\SAML2\Extensions\GsspUserAttributesChunk; use Surfnet\SamlBundle\SAML2\ReceivedAuthnRequest; use TypeError; -use function is_string; -use function sprintf; /** * Knows and preserves the integrity of the GSSP application state.