From adf007b37992ca977ddae9ff3e71f31b5d0d386e Mon Sep 17 00:00:00 2001 From: Matthieu Date: Tue, 7 Apr 2026 11:41:31 +0200 Subject: [PATCH] fix : autowire persist processor in UserPasswordHasherProcessor Co-Authored-By: Claude Opus 4.6 (1M context) --- src/Api/Auth/State/UserPasswordHasherProcessor.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Api/Auth/State/UserPasswordHasherProcessor.php b/src/Api/Auth/State/UserPasswordHasherProcessor.php index 439c8ea..7a24386 100644 --- a/src/Api/Auth/State/UserPasswordHasherProcessor.php +++ b/src/Api/Auth/State/UserPasswordHasherProcessor.php @@ -7,6 +7,7 @@ namespace App\Api\Auth\State; use ApiPlatform\Metadata\Operation; use ApiPlatform\State\ProcessorInterface; use App\Entity\User; +use Symfony\Component\DependencyInjection\Attribute\Autowire; use Symfony\Component\PasswordHasher\Hasher\UserPasswordHasherInterface; /** @@ -15,7 +16,7 @@ use Symfony\Component\PasswordHasher\Hasher\UserPasswordHasherInterface; class UserPasswordHasherProcessor implements ProcessorInterface { public function __construct( - /** @var ProcessorInterface */ + #[Autowire(service: 'api_platform.doctrine.orm.state.persist_processor')] private readonly ProcessorInterface $persistProcessor, private readonly UserPasswordHasherInterface $passwordHasher, ) {}