|
|
@ -78,8 +78,13 @@ abstract class AbstractPicoPlugin implements PicoPluginInterface |
|
|
|
if (is_array($pluginConfig) && isset($pluginConfig['enabled'])) { |
|
|
|
if (is_array($pluginConfig) && isset($pluginConfig['enabled'])) { |
|
|
|
$this->setEnabled($pluginConfig['enabled']); |
|
|
|
$this->setEnabled($pluginConfig['enabled']); |
|
|
|
} elseif ($this->enabled) { |
|
|
|
} elseif ($this->enabled) { |
|
|
|
// make sure dependencies are fulfilled |
|
|
|
// make sure dependencies are already fulfilled, |
|
|
|
$this->checkDependencies(true); |
|
|
|
// otherwise the plugin needs to be enabled manually |
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
$this->checkDependencies(false); |
|
|
|
|
|
|
|
} catch (RuntimeException $e) { |
|
|
|
|
|
|
|
$this->enabled = false; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|