Added a DISABLE_LOGOUT constant, to allow the logout command to be disabled, for support of external SSO solutions.

This commit is contained in:
Dj Padzensky
2016-02-12 15:56:13 -08:00
parent 77ae92b09b
commit 773bf36733
3 changed files with 17 additions and 7 deletions

View File

@@ -55,8 +55,13 @@ class Auth extends Base
*/
public function logout()
{
$this->sessionManager->close();
$this->response->redirect($this->helper->url->to('auth', 'login'));
if (! DISABLE_LOGOUT) {
$this->sessionManager->close();
$this->response->redirect($this->helper->url->to('auth', 'login'));
}
else {
$this->response->redirect($this->helper->url->to('auth', 'index'));
}
}
/**