diff --git a/include/class.ostsession.php b/include/class.ostsession.php index fb840d2f8186213506274c0e385170d88da1d2d2..78b118299f2ceac11acc85206ab212740cb8079a 100644 --- a/include/class.ostsession.php +++ b/include/class.ostsession.php @@ -25,7 +25,12 @@ class osTicketSession { if(!$this->ttl) $this->ttl=SESSION_TTL; - if (defined('DISABLE_SESSION') || OsticketConfig::getDBVersion()) + session_name('OSTSESSID'); + + if (OsticketConfig::getDBVersion()) + return session_start(); + + elseif (defined('DISABLE_SESSION')) return; # Cookies @@ -54,7 +59,6 @@ class osTicketSession { register_shutdown_function('session_write_close'); //Start the session. - session_name('OSTSESSID'); session_start(); }