mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-31 09:06:17 +00:00
Fix incorrect value being stored in Auth.redirect.
An incorrect value would be stored in Auth.redirect when a custom route with the `pass` key set. Fixes #2366
This commit is contained in:
parent
4ed2185876
commit
321caf6db6
1 changed files with 1 additions and 1 deletions
|
@ -314,7 +314,7 @@ class AuthComponent extends Component {
|
|||
if (!$this->_getUser()) {
|
||||
if (!$request->is('ajax')) {
|
||||
$this->flash($this->authError);
|
||||
$this->Session->write('Auth.redirect', Router::reverse($request));
|
||||
$this->Session->write('Auth.redirect', $request->here());
|
||||
$controller->redirect($loginAction);
|
||||
return false;
|
||||
} elseif (!empty($this->ajaxLogin)) {
|
||||
|
|
Loading…
Add table
Reference in a new issue