Adding fix for #2648, fixes issue with token not being regenerated

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@5251 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
phpnut 2007-06-06 17:28:32 +00:00
parent 41d41cf7e2
commit 3ed6780ac4

View file

@ -145,10 +145,11 @@ class SecurityComponent extends Object {
$this->__secureRequired($controller); $this->__secureRequired($controller);
$this->__authRequired($controller); $this->__authRequired($controller);
$this->__loginRequired($controller); $this->__loginRequired($controller);
if($this->RequestHandler->isPost()) {
if((!isset($controller->params['requested']) || $controller->params['requested'] != 1) && $this->RequestHandler->isPost()) {
$this->__validatePost($controller); $this->__validatePost($controller);
return;
} }
$this->__generateToken($controller); $this->__generateToken($controller);
} }
/** /**