ActionController: remove redirectToLogin default
The redirectOnLogin function now doesn't have any predefined default. This also leads to the behaviour that "Logout" will not redirect you anywhere on a new login while "forcibly being logged out" (e.g. by logging out in another browser tab) will bring you back to where you came from.
This commit is contained in:
parent
7334716d15
commit
db3ef8fbd0
|
@ -254,8 +254,10 @@ class ActionController extends Zend_Controller_Action
|
|||
*
|
||||
* @throws \Exception
|
||||
*/
|
||||
protected function redirectToLogin($afterLogin = '/dashboard')
|
||||
protected function redirectToLogin($afterLogin = null)
|
||||
{
|
||||
$redir = null;
|
||||
if ($afterLogin !== null) {
|
||||
if (! $afterLogin instanceof Url) {
|
||||
$afterLogin = Url::fromPath($afterLogin);
|
||||
}
|
||||
|
@ -265,7 +267,10 @@ class ActionController extends Zend_Controller_Action
|
|||
// TODO: Ignore /?
|
||||
$redir = $afterLogin->getRelativeUrl();
|
||||
}
|
||||
}
|
||||
|
||||
$url = Url::fromPath('authentication/login');
|
||||
|
||||
if ($redir) {
|
||||
$url->setParam('redirect', $redir);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue