mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-14 00:24:40 +00:00
(mvc) trash session userdata on timeout
This commit is contained in:
parent
9e1890af4a
commit
d0fcd23536
@ -77,6 +77,9 @@ class ControllerRoot extends Controller
|
||||
&& $this->session->get("last_access") < (time() - 14400)) {
|
||||
// session expired (todo, use config timeout)
|
||||
$this->getLogger()->error("session expired");
|
||||
// cleanup session data
|
||||
$this->session->remove("Username");
|
||||
$this->session->remove("last_access");
|
||||
$this->response->redirect("/", true);
|
||||
return false;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user