From 8d618d4e29feb9e6bd68ed8d59e79e08b245d23a Mon Sep 17 00:00:00 2001 From: Sam Georges Date: Thu, 16 Oct 2014 19:48:21 +1100 Subject: [PATCH] Fixes #684 - Plugins still load language, routes, etc when noInit is enabled --- modules/system/classes/PluginManager.php | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/modules/system/classes/PluginManager.php b/modules/system/classes/PluginManager.php index 2da124526..9d5616105 100644 --- a/modules/system/classes/PluginManager.php +++ b/modules/system/classes/PluginManager.php @@ -116,14 +116,16 @@ class PluginManager */ public function registerAll() { - if ($this->registered || self::$noInit) + if ($this->registered) return; foreach ($this->plugins as $pluginId => $plugin) { if ($plugin->disabled) continue; - $plugin->register(); + if (!self::$noInit) + $plugin->register(); + $pluginPath = $this->getPluginPath($plugin); $pluginNamespace = strtolower($pluginId); @@ -171,14 +173,15 @@ class PluginManager */ public function bootAll() { - if ($this->booted || self::$noInit) + if ($this->booted) return; foreach ($this->plugins as $plugin) { if ($plugin->disabled) continue; - $plugin->boot(); + if (!self::$noInit) + $plugin->boot(); } $this->booted = true;