From 2a835855b951b2351735d26adec50421ac5a312e Mon Sep 17 00:00:00 2001 From: Matthieu Date: Thu, 23 Apr 2026 11:44:02 +0200 Subject: [PATCH] refactor(api) : passe UserPasswordHasherProcessor et MeProvider en final MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit T-012 — aligne ces deux classes sur la convention de la PR (tous les autres providers/processors sont final). Empeche une sous-classe de contourner la logique de hachage ou l'auth Me par heritage accidentel. --- .../ApiPlatform/State/Processor/UserPasswordHasherProcessor.php | 2 +- .../Infrastructure/ApiPlatform/State/Provider/MeProvider.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Module/Core/Infrastructure/ApiPlatform/State/Processor/UserPasswordHasherProcessor.php b/src/Module/Core/Infrastructure/ApiPlatform/State/Processor/UserPasswordHasherProcessor.php index 92fb4e2..c45d529 100644 --- a/src/Module/Core/Infrastructure/ApiPlatform/State/Processor/UserPasswordHasherProcessor.php +++ b/src/Module/Core/Infrastructure/ApiPlatform/State/Processor/UserPasswordHasherProcessor.php @@ -13,7 +13,7 @@ use Symfony\Component\PasswordHasher\Hasher\UserPasswordHasherInterface; /** * @implements ProcessorInterface */ -class UserPasswordHasherProcessor implements ProcessorInterface +final class UserPasswordHasherProcessor implements ProcessorInterface { public function __construct( #[Autowire(service: 'api_platform.doctrine.orm.state.persist_processor')] diff --git a/src/Module/Core/Infrastructure/ApiPlatform/State/Provider/MeProvider.php b/src/Module/Core/Infrastructure/ApiPlatform/State/Provider/MeProvider.php index ea088c8..ab62c08 100644 --- a/src/Module/Core/Infrastructure/ApiPlatform/State/Provider/MeProvider.php +++ b/src/Module/Core/Infrastructure/ApiPlatform/State/Provider/MeProvider.php @@ -11,7 +11,7 @@ use Symfony\Bundle\SecurityBundle\Security; /** * @implements ProviderInterface */ -class MeProvider implements ProviderInterface +final class MeProvider implements ProviderInterface { public function __construct( private readonly Security $security,