apply rector rules: php up to php82

This commit is contained in:
2023-07-19 23:16:01 +02:00
parent 7b637d1287
commit 023a29cb78
744 changed files with 1369 additions and 1381 deletions

View File

@@ -24,7 +24,7 @@ use Symfony\Component\Routing\Annotation\Route;
class CalendarAPIController extends ApiController
{
public function __construct(private CalendarRepository $calendarRepository)
public function __construct(private readonly CalendarRepository $calendarRepository)
{
}

View File

@@ -49,8 +49,20 @@ use Symfony\Contracts\Translation\TranslatorInterface;
class CalendarController extends AbstractController
{
public function __construct(private CalendarACLAwareRepositoryInterface $calendarACLAwareRepository, private DocGeneratorTemplateRepository $docGeneratorTemplateRepository, private FilterOrderHelperFactoryInterface $filterOrderHelperFactory, private LoggerInterface $logger, private PaginatorFactory $paginator, private RemoteCalendarConnectorInterface $remoteCalendarConnector, private SerializerInterface $serializer, private TranslatableStringHelperInterface $translatableStringHelper, private PersonRepository $personRepository, private AccompanyingPeriodRepository $accompanyingPeriodRepository, private UserRepositoryInterface $userRepository, private TranslatorInterface $translator)
{
public function __construct(
private readonly CalendarACLAwareRepositoryInterface $calendarACLAwareRepository,
private readonly DocGeneratorTemplateRepository $docGeneratorTemplateRepository,
private readonly FilterOrderHelperFactoryInterface $filterOrderHelperFactory,
private readonly LoggerInterface $logger,
private readonly PaginatorFactory $paginator,
private readonly RemoteCalendarConnectorInterface $remoteCalendarConnector,
private readonly SerializerInterface $serializer,
private readonly TranslatableStringHelperInterface $translatableStringHelper,
private readonly PersonRepository $personRepository,
private readonly AccompanyingPeriodRepository $accompanyingPeriodRepository,
private readonly UserRepositoryInterface $userRepository,
private readonly TranslatorInterface $translator
) {
}
/**

View File

@@ -31,12 +31,15 @@ use Symfony\Component\Serializer\SerializerInterface;
use Symfony\Component\Templating\EngineInterface;
use UnexpectedValueException;
class CalendarDocController
final readonly class CalendarDocController
{
private SerializerInterface $serializer;
public function __construct(private DocGeneratorTemplateRepository $docGeneratorTemplateRepository, private EngineInterface $engine, private EntityManagerInterface $entityManager, private FormFactoryInterface $formFactory, private Security $security, private UrlGeneratorInterface $urlGenerator)
{
public function __construct(
private EngineInterface $engine,
private EntityManagerInterface $entityManager,
private FormFactoryInterface $formFactory,
private Security $security,
private UrlGeneratorInterface $urlGenerator,
) {
}
/**

View File

@@ -25,7 +25,7 @@ use Symfony\Component\Routing\Annotation\Route;
class CalendarRangeAPIController extends ApiController
{
public function __construct(private CalendarRangeRepository $calendarRangeRepository)
public function __construct(private readonly CalendarRangeRepository $calendarRangeRepository)
{
}

View File

@@ -35,7 +35,7 @@ use function in_array;
class InviteApiController
{
public function __construct(private EntityManagerInterface $entityManager, private MessageBusInterface $messageBus, private Security $security)
public function __construct(private readonly EntityManagerInterface $entityManager, private readonly MessageBusInterface $messageBus, private readonly Security $security)
{
}

View File

@@ -30,7 +30,7 @@ use TheNetworg\OAuth2\Client\Token\AccessToken;
class RemoteCalendarConnectAzureController
{
public function __construct(private ClientRegistry $clientRegistry, private OnBehalfOfUserTokenStorage $MSGraphTokenStorage)
public function __construct(private readonly ClientRegistry $clientRegistry, private readonly OnBehalfOfUserTokenStorage $MSGraphTokenStorage)
{
}

View File

@@ -29,7 +29,7 @@ use const JSON_THROW_ON_ERROR;
class RemoteCalendarMSGraphSyncController
{
public function __construct(private MessageBusInterface $messageBus)
public function __construct(private readonly MessageBusInterface $messageBus)
{
}

View File

@@ -36,7 +36,7 @@ use function count;
*/
class RemoteCalendarProxyController
{
public function __construct(private PaginatorFactory $paginatorFactory, private RemoteCalendarConnectorInterface $remoteCalendarConnector, private SerializerInterface $serializer)
public function __construct(private readonly PaginatorFactory $paginatorFactory, private readonly RemoteCalendarConnectorInterface $remoteCalendarConnector, private readonly SerializerInterface $serializer)
{
}