DX: apply rector rules up to php8.0

This commit is contained in:
2023-04-15 01:05:37 +02:00
parent d8870e906f
commit dde3002100
714 changed files with 2348 additions and 9263 deletions

View File

@@ -47,68 +47,20 @@ use function is_array;
final class PersonController extends AbstractController
{
private AuthorizationHelperInterface $authorizationHelper;
/**
* @var ConfigPersonAltNamesHelper
*/
protected $configPersonAltNameHelper;
/**
* @var EventDispatcherInterface
*/
protected $eventDispatcher;
/**
* @var PersonRepository;
*/
protected $personRepository;
/**
* @var SimilarPersonMatcher
*/
protected $similarPersonMatcher;
/**
* @var TranslatorInterface
*/
protected $translator;
/**
* @var EntityManagerInterface
*/
private $em;
/**
* @var \Psr\Log\LoggerInterface
*/
private $logger;
/**
* @var ValidatorInterface
*/
private $validator;
public function __construct(
AuthorizationHelperInterface $authorizationHelper,
SimilarPersonMatcher $similarPersonMatcher,
TranslatorInterface $translator,
EventDispatcherInterface $eventDispatcher,
PersonRepository $personRepository,
ConfigPersonAltNamesHelper $configPersonAltNameHelper,
LoggerInterface $logger,
ValidatorInterface $validator,
EntityManagerInterface $em,
private AuthorizationHelperInterface $authorizationHelper,
protected SimilarPersonMatcher $similarPersonMatcher,
protected TranslatorInterface $translator,
protected EventDispatcherInterface $eventDispatcher,
/**
* @var PersonRepository;
*/
protected PersonRepository $personRepository,
protected ConfigPersonAltNamesHelper $configPersonAltNameHelper,
private LoggerInterface $logger,
private ValidatorInterface $validator,
private EntityManagerInterface $em
) {
$this->authorizationHelper = $authorizationHelper;
$this->similarPersonMatcher = $similarPersonMatcher;
$this->translator = $translator;
$this->eventDispatcher = $eventDispatcher;
$this->configPersonAltNameHelper = $configPersonAltNameHelper;
$this->personRepository = $personRepository;
$this->logger = $logger;
$this->validator = $validator;
$this->em = $em;
}
public function editAction($person_id, Request $request)
@@ -335,11 +287,10 @@ final class PersonController extends AbstractController
/**
* easy getting a person by his id.
*
* @param mixed $id
*
* @return \Chill\PersonBundle\Entity\Person
*/
private function _getPerson($id)
private function _getPerson(mixed $id)
{
return $this->personRepository->find($id);
}