Apply rector rules: symfony up to 54

This commit is contained in:
2024-04-04 23:30:25 +02:00
parent 1ee3b9e2f0
commit 579bd829f8
204 changed files with 974 additions and 2346 deletions

View File

@@ -49,9 +49,7 @@ final class PersonController extends AbstractController
private readonly EntityManagerInterface $em,
) {}
/**
* @\Symfony\Component\Routing\Annotation\Route(path="/{_locale}/person/{person_id}/general/edit", name="chill_person_general_edit")
*/
#[Route(path: '/{_locale}/person/{person_id}/general/edit', name: 'chill_person_general_edit')]
public function editAction(int $person_id, Request $request)
{
$person = $this->_getPerson($person_id);
@@ -116,14 +114,9 @@ final class PersonController extends AbstractController
}
/**
* @Route(
* "/{_locale}/person/household/{person_id}/history",
* name="chill_person_household_person_history",
* methods={"GET", "POST"}
* )
*
* @ParamConverter("person", options={"id": "person_id"})
*/
#[Route(path: '/{_locale}/person/household/{person_id}/history', name: 'chill_person_household_person_history', methods: ['GET', 'POST'])]
public function householdHistoryByPerson(Request $request, Person $person): Response
{
$this->denyAccessUnlessGranted(
@@ -146,14 +139,13 @@ final class PersonController extends AbstractController
/**
* Method for creating a new person.
*
*The controller register data from a previous post on the form, and
* The controller register data from a previous post on the form, and
* register it in the session.
*
* The next post compare the data with previous one and, if yes, show a
* review page if there are "alternate persons".
*
* @\Symfony\Component\Routing\Annotation\Route(path="/{_locale}/person/new", name="chill_person_new")
*/
#[Route(path: '/{_locale}/person/new', name: 'chill_person_new')]
public function newAction(Request $request): Response
{
$person = new Person();
@@ -248,9 +240,7 @@ final class PersonController extends AbstractController
);
}
/**
* @\Symfony\Component\Routing\Annotation\Route(path="/{_locale}/person/{person_id}/general", name="chill_person_view")
*/
#[Route(path: '/{_locale}/person/{person_id}/general', name: 'chill_person_view')]
public function viewAction(int $person_id)
{
$person = $this->_getPerson($person_id);