public function index($redir = '') { $userId = $this->session->getLoggedInUserId(); $this->session->destroySession(); $this->session->startSession($userId); return new Redirection($redir ?: '/members'); }
public function index() { $this->dispatcher->fire(UserLogoutEvent::USER_LOGOUT_SUCCESS, new UserLogoutEvent($this->session->getLoggedInUserId())); $this->session->destroySession(); return new Redirection('/'); }