mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-29 19:13:49 +00:00
DX: apply rector rules up to php8.0
This commit is contained in:
@@ -26,47 +26,10 @@ use Symfony\Contracts\Translation\TranslatorInterface;
|
||||
|
||||
final class OnGenerationFails implements EventSubscriberInterface
|
||||
{
|
||||
private DocGeneratorTemplateRepository $docGeneratorTemplateRepository;
|
||||
|
||||
private EntityManagerInterface $entityManager;
|
||||
|
||||
private LoggerInterface $logger;
|
||||
|
||||
private MailerInterface $mailer;
|
||||
|
||||
private StoredObjectRepository $storedObjectRepository;
|
||||
|
||||
private TranslatorInterface $translator;
|
||||
|
||||
private UserRepositoryInterface $userRepository;
|
||||
|
||||
public const LOG_PREFIX = '[docgen failed] ';
|
||||
|
||||
/**
|
||||
* @param DocGeneratorTemplateRepository $docGeneratorTemplateRepository
|
||||
* @param EntityManagerInterface $entityManager
|
||||
* @param LoggerInterface $logger
|
||||
* @param MailerInterface $mailer
|
||||
* @param StoredObjectRepository $storedObjectRepository
|
||||
* @param TranslatorInterface $translator
|
||||
* @param UserRepositoryInterface $userRepository
|
||||
*/
|
||||
public function __construct(
|
||||
DocGeneratorTemplateRepository $docGeneratorTemplateRepository,
|
||||
EntityManagerInterface $entityManager,
|
||||
LoggerInterface $logger,
|
||||
MailerInterface $mailer,
|
||||
StoredObjectRepository $storedObjectRepository,
|
||||
TranslatorInterface $translator,
|
||||
UserRepositoryInterface $userRepository
|
||||
) {
|
||||
$this->docGeneratorTemplateRepository = $docGeneratorTemplateRepository;
|
||||
$this->entityManager = $entityManager;
|
||||
$this->logger = $logger;
|
||||
$this->mailer = $mailer;
|
||||
$this->storedObjectRepository = $storedObjectRepository;
|
||||
$this->translator = $translator;
|
||||
$this->userRepository = $userRepository;
|
||||
public function __construct(private DocGeneratorTemplateRepository $docGeneratorTemplateRepository, private EntityManagerInterface $entityManager, private LoggerInterface $logger, private MailerInterface $mailer, private StoredObjectRepository $storedObjectRepository, private TranslatorInterface $translator, private UserRepositoryInterface $userRepository)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@@ -95,7 +58,7 @@ final class OnGenerationFails implements EventSubscriberInterface
|
||||
'entity_id' => $message->getEntityId(),
|
||||
'template_id' => $message->getTemplateId(),
|
||||
'creator_id' => $message->getCreatorId(),
|
||||
'throwable_class' => get_class($event->getThrowable()),
|
||||
'throwable_class' => $event->getThrowable()::class,
|
||||
]);
|
||||
|
||||
$this->markObjectAsFailed($message);
|
||||
|
Reference in New Issue
Block a user