src/Controller/SecurityController.php line 22
<?phpnamespace App\Controller;use App\Entity\Log;use App\Entity\User;use Doctrine\Persistence\ManagerRegistry;use Symfony\Component\Routing\Annotation\Route;use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;use Symfony\Component\HttpFoundation\Request;use Symfony\Component\Security\Http\Authentication\AuthenticationUtils;class SecurityController extends AbstractController{/*** @Route("/login", name="login")* @param Request $request* @param AuthenticationUtils $authenticationUtils* @return \Symfony\Component\HttpFoundation\Response*/public function login(Request $request, AuthenticationUtils $authenticationUtils){// get the login error if there is one$error = $authenticationUtils->getLastAuthenticationError();// last username entered by the user$lastUsername = $authenticationUtils->getLastUsername();return $this->render('security/login.html.twig', array('last_username' => $lastUsername,'error' => $error,));}}