Removed loading login.class.php from lib2/common.inc.php. So no $login variable is propagated anymore (for lib2).
Fixed all calls in index.php and included files. DID NOT YET FIX OTHER PAGES! THEY WILL BREAK! N.B.: Instead of $login->..., you now have to do $GLOBALS['container']->get('ocde.login')->...
This commit is contained in:
@ -86,7 +86,6 @@ require_once __DIR__ . '/../lib/core.php';
|
||||
require_once($GLOBALS['container']->get('ocde.config')->getBaseDir() . '/lib2/error.inc.php');
|
||||
require_once($GLOBALS['container']->get('ocde.config')->getBaseDir() . '/lib2/util.inc.php');
|
||||
require_once($GLOBALS['container']->get('ocde.config')->getBaseDir() . '/lib2/db.inc.php');
|
||||
require_once($GLOBALS['container']->get('ocde.config')->getBaseDir() . '/lib2/login2.class.php');
|
||||
require_once($GLOBALS['container']->get('ocde.config')->getBaseDir() . '/lib2/menu.class.php');
|
||||
require_once($GLOBALS['container']->get('ocde.config')->getBaseDir() . '/lib2/logic/labels.inc.php');
|
||||
|
||||
@ -98,8 +97,8 @@ require_once __DIR__ . '/../lib/core.php';
|
||||
// use direct database access instead of user class for performance reasons - need not
|
||||
// to include user.class.php in any script
|
||||
if (!isset($disable_verifyemail) &&
|
||||
$login->userid > 0 &&
|
||||
sql_value("SELECT `email_problems` FROM `user` WHERE `user_id`='&1'", 0, $login->userid) != 0)
|
||||
$GLOBALS['container']->get('ocde.login')->getUserId() > 0 &&
|
||||
sql_value("SELECT `email_problems` FROM `user` WHERE `user_id`='&1'", 0, $GLOBALS['container']->get('ocde.login')->getUserId()) != 0)
|
||||
{
|
||||
header("Location: verifyemail.php?page=" . basename($_SERVER['REQUEST_URI']));
|
||||
exit;
|
||||
|
Reference in New Issue
Block a user