diff --git a/book/security.rst b/book/security.rst index e9b41a08aee..d73823f3f1b 100644 --- a/book/security.rst +++ b/book/security.rst @@ -416,13 +416,13 @@ Next, create the controller that will display the login form:: namespace Acme\SecurityBundle\Controller; use Symfony\Bundle\FrameworkBundle\Controller\Controller; + use Symfony\Component\HttpFoundation\Request; use Symfony\Component\Security\Core\SecurityContext; class SecurityController extends Controller { - public function loginAction() + public function loginAction(Request $request) { - $request = $this->getRequest(); $session = $request->getSession(); // get the login error if there is one