src/Controller/FeedbackController.php line 22
<?phpnamespace App\Controller;use App\Dto\FeedbackDto;use App\Exception\AppException;use App\Form\FeedbackType;use App\Notification\NotifierInterface;use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;use Symfony\Component\HttpFoundation\Request;use Symfony\Component\HttpFoundation\Response;use Symfony\Component\Routing\Annotation\Route;#[Route('/feedback')]class FeedbackController extends AbstractController{/*** @throws AppException*/#[Route('/', name: 'app_feedback', methods: ['GET', 'POST'])]public function feedback(Request $request,NotifierInterface $notifier,): Response{$feedback = new FeedbackDto();$form = $this->createForm(FeedbackType::class, $feedback);$form->handleRequest($request);if ($form->isSubmitted() && $form->isValid()) {$notifier->sendFeedback($feedback);}return $this->render('feedback/feedback.html.twig', ['form' => $form,]);}}