mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-04 05:44:58 +00:00
apply rector rules: php up to php82
This commit is contained in:
@@ -22,7 +22,7 @@ use Symfony\Component\Routing\RouteCollection;
|
||||
*/
|
||||
class ChillRoutesLoader extends Loader
|
||||
{
|
||||
public function __construct(private array $routes)
|
||||
public function __construct(private readonly array $routes)
|
||||
{
|
||||
parent::__construct();
|
||||
}
|
||||
|
@@ -22,7 +22,6 @@ interface LocalMenuBuilderInterface
|
||||
{
|
||||
/**
|
||||
* @param $menuId
|
||||
* @param MenuItem $menu
|
||||
* @param TParams $parameters
|
||||
*/
|
||||
public function buildMenu($menuId, MenuItem $menu, array $parameters);
|
||||
|
@@ -22,7 +22,7 @@ use Symfony\Contracts\Translation\TranslatorInterface;
|
||||
|
||||
class UserMenuBuilder implements LocalMenuBuilderInterface
|
||||
{
|
||||
public function __construct(private NotificationByUserCounter $notificationByUserCounter, private WorkflowByUserCounter $workflowByUserCounter, private Security $security, private TranslatorInterface $translator, protected ParameterBagInterface $parameterBag, private RequestStack $requestStack)
|
||||
public function __construct(private readonly NotificationByUserCounter $notificationByUserCounter, private readonly WorkflowByUserCounter $workflowByUserCounter, private readonly Security $security, private readonly TranslatorInterface $translator, protected ParameterBagInterface $parameterBag, private readonly RequestStack $requestStack)
|
||||
{
|
||||
}
|
||||
|
||||
|
@@ -33,7 +33,7 @@ class MenuComposer
|
||||
|
||||
private RouteCollection $routeCollection;
|
||||
|
||||
public function __construct(private RouterInterface $router, private FactoryInterface $menuFactory, private TranslatorInterface $translator)
|
||||
public function __construct(private readonly RouterInterface $router, private readonly FactoryInterface $menuFactory, private readonly TranslatorInterface $translator)
|
||||
{
|
||||
}
|
||||
|
||||
|
@@ -38,7 +38,7 @@ class MenuTwig extends AbstractExtension implements ContainerAwareInterface
|
||||
'activeRouteKey' => null,
|
||||
];
|
||||
|
||||
public function __construct(private MenuComposer $menuComposer)
|
||||
public function __construct(private readonly MenuComposer $menuComposer)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -76,7 +76,7 @@ class MenuTwig extends AbstractExtension implements ContainerAwareInterface
|
||||
{
|
||||
return [new TwigFunction(
|
||||
'chill_menu',
|
||||
[$this, 'chillMenu'],
|
||||
$this->chillMenu(...),
|
||||
[
|
||||
'is_safe' => ['html'],
|
||||
'needs_environment' => true,
|
||||
|
Reference in New Issue
Block a user