mirror of
https://github.com/Combodo/iTop.git
synced 2026-05-21 08:12:26 +02:00
N°2439 Add real autoloader for framework files (not modules)
This commit is contained in:
@@ -32,13 +32,13 @@ require_once APPROOT.'/lib/autoload.php';
|
||||
// Load current environment if necessary (typically from CLI as the app is not started yet)
|
||||
if (!defined('MODULESROOT'))
|
||||
{
|
||||
if (file_exists(__DIR__.'/../../../../approot.inc.php'))
|
||||
if (file_exists(__DIR__.'/../../../../bootstrap.inc.php'))
|
||||
{
|
||||
require_once __DIR__.'/../../../../approot.inc.php'; // When in env-xxxx folder
|
||||
require_once __DIR__.'/../../../../bootstrap.inc.php'; // When in env-xxxx folder
|
||||
}
|
||||
else
|
||||
{
|
||||
require_once __DIR__.'/../../../../../approot.inc.php'; // When in datamodels/x.x folder
|
||||
require_once __DIR__.'/../../../../../bootstrap.inc.php'; // When in datamodels/x.x folder
|
||||
}
|
||||
require_once APPROOT.'/application/startup.inc.php';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user