Skip to content

Commit 8ee991d

Browse files
committed
Merge branch '6.2' into 6.3
* 6.2: Task object instead of id as param
2 parents 820e943 + 4cf29bc commit 8ee991d

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

form/form_collections.rst

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -643,12 +643,8 @@ the relationship between the removed ``Tag`` and ``Task`` object.
643643

644644
class TaskController extends AbstractController
645645
{
646-
public function edit($id, Request $request, EntityManagerInterface $entityManager): Response
646+
public function edit(Task $task, Request $request, EntityManagerInterface $entityManager): Response
647647
{
648-
if (null === $task = $entityManager->getRepository(Task::class)->find($id)) {
649-
throw $this->createNotFoundException('No task found for id '.$id);
650-
}
651-
652648
$originalTags = new ArrayCollection();
653649

654650
// Create an ArrayCollection of the current Tag objects in the database

0 commit comments

Comments
 (0)