We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents a43b073 + 38e9adb commit 9962551Copy full SHA for 9962551
src/Controller/SecurityController.php
@@ -36,7 +36,7 @@ class SecurityController extends AbstractController
36
public function login(Request $request, Security $security, AuthenticationUtils $helper): Response
37
{
38
// if user is already logged in, don't display the login page again
39
- if ($security->isGranted('ROLE_USER')) {
+ if ($this->getUser()) {
40
return $this->redirectToRoute('blog_index');
41
}
42
0 commit comments