Added a very basic system to disabled modules using $enabled = false; in the moduleInfo.php

This commit is contained in:
Abel Hoogeveen 2015-03-14 16:03:38 +01:00
parent 892068d583
commit 44ae54445e
1 changed files with 7 additions and 0 deletions

View File

@ -95,6 +95,13 @@ class Core {
// Load the config file
$cfg = (object) $this->register[$name];
// Check if the module is enabled, otherwise abort
if (isset($cfg->enabled)) {
if (!$cfg->enabled) {
return false;
}
}
// Check if a specific version is requested
if (isset($version)) {
if (isset($cfg->versions)) {