Skip to content
Snippets Groups Projects
Commit b55e2b7e authored by tbrehm's avatar tbrehm
Browse files
Added destructor and session write to app class instead.
parent 552714c3
No related branches found
No related tags found
No related merge requests found
......@@ -75,6 +75,11 @@ class app {
$this->uses('auth,plugin,functions');
}
public function __destruct() {
session_write_close();
if(isset($this->db)) $this->db->closeConn();
}
public function uses($classes) {
$cl = explode(',', $classes);
......
......@@ -54,10 +54,6 @@ class db {
//$this->connect();
}
public function __destruct() {
$this->closeConn();
}
/** Error handler */
public function updateError($location)
{
......
......@@ -64,6 +64,7 @@ $app->plugin->raiseEvent('logout',true);
$_SESSION["s"]["user"] = null;
$_SESSION["s"]["module"] = null;
$_SESSION['s_old'] = null;
session_write_close();
//header("Location: ../index.php?phpsessid=".$_SESSION["s"]["id"]);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment