Repair redirect after login

fixes #10287
This commit is contained in:
Alexander A. Klimov 2015-10-22 16:29:37 +02:00
parent fdb186ec56
commit da744caaef

View File

@ -71,7 +71,7 @@ class LoginForm extends Form
if ($this->created) { if ($this->created) {
$redirect = $this->getElement('redirect')->getValue(); $redirect = $this->getElement('redirect')->getValue();
} }
if (empty($redirect) || strpos($redirect, 'authentication/logout') !== 0) { if (empty($redirect) || strpos($redirect, 'authentication/logout') !== false) {
$redirect = static::REDIRECT_URL; $redirect = static::REDIRECT_URL;
} }
return Url::fromPath($redirect); return Url::fromPath($redirect);