ApplicationBootstrap: Process `ICINGAWEB_MODULES_DIR` by default
This commit is contained in:
parent
db9888b1f1
commit
e7adc06497
|
@ -452,10 +452,15 @@ abstract class ApplicationBootstrap
|
|||
|
||||
protected function getAvailableModulePaths()
|
||||
{
|
||||
$paths = array();
|
||||
$configured = $this->config->get('global', 'module_path', $this->baseDir . '/modules');
|
||||
$paths = [];
|
||||
|
||||
$configured = getenv('ICINGAWEB_MODULES_DIR');
|
||||
if (! $configured) {
|
||||
$configured = $this->config->get('global', 'module_path', $this->baseDir . '/modules');
|
||||
}
|
||||
|
||||
$nextIsPhar = false;
|
||||
foreach (explode(':', $configured) as $path) {
|
||||
foreach (explode(PATH_SEPARATOR, $configured) as $path) {
|
||||
if ($path === 'phar') {
|
||||
$nextIsPhar = true;
|
||||
continue;
|
||||
|
|
|
@ -197,10 +197,10 @@ class PhpCommand extends Command
|
|||
$vars[] = sprintf('ICINGAWEB_MODULE_DIRS=%s', implode(':', $modulePaths));
|
||||
|
||||
// Disabled as the bootstrap.php for PHPUnit and class BaseTestCase can't handle multiple paths yet
|
||||
/*$vars[] = sprintf(
|
||||
$vars[] = sprintf(
|
||||
'ICINGAWEB_MODULES_DIR=%s',
|
||||
implode(PATH_SEPARATOR, $this->app->getModuleManager()->getModuleDirs())
|
||||
);*/
|
||||
);
|
||||
|
||||
return join(' ', $vars) . ' ';
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue