variable with installed plugins
This commit is contained in:
parent
1419483708
commit
9d436f8a76
|
@ -43,6 +43,8 @@ $plugins = array(
|
||||||
$pluginsEvents = $plugins;
|
$pluginsEvents = $plugins;
|
||||||
unset($pluginsEvents['all']);
|
unset($pluginsEvents['all']);
|
||||||
|
|
||||||
|
$pluginsInstalled = array();
|
||||||
|
|
||||||
// ============================================================================
|
// ============================================================================
|
||||||
// Functions
|
// Functions
|
||||||
// ============================================================================
|
// ============================================================================
|
||||||
|
@ -51,6 +53,7 @@ function buildPlugins()
|
||||||
{
|
{
|
||||||
global $plugins;
|
global $plugins;
|
||||||
global $pluginsEvents;
|
global $pluginsEvents;
|
||||||
|
global $pluginsInstalled;
|
||||||
global $L;
|
global $L;
|
||||||
global $site;
|
global $site;
|
||||||
|
|
||||||
|
@ -98,6 +101,7 @@ function buildPlugins()
|
||||||
|
|
||||||
// If the plugin is installed insert on the hooks
|
// If the plugin is installed insert on the hooks
|
||||||
if ($Plugin->installed()) {
|
if ($Plugin->installed()) {
|
||||||
|
$pluginsInstalled[$pluginClass] = $Plugin;
|
||||||
foreach ($pluginsEvents as $event=>$value) {
|
foreach ($pluginsEvents as $event=>$value) {
|
||||||
if (method_exists($Plugin, $event)) {
|
if (method_exists($Plugin, $event)) {
|
||||||
array_push($plugins[$event], $Plugin);
|
array_push($plugins[$event], $Plugin);
|
||||||
|
|
Loading…
Reference in New Issue