aboutsummaryrefslogtreecommitdiffstats
path: root/admin/include/plugins.class.php
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--admin/include/plugins.class.php26
1 files changed, 14 insertions, 12 deletions
diff --git a/admin/include/plugins.class.php b/admin/include/plugins.class.php
index 197bed678..e5e6d47f4 100644
--- a/admin/include/plugins.class.php
+++ b/admin/include/plugins.class.php
@@ -29,29 +29,31 @@ class DummyPlugin_maintain extends PluginMaintain
{
function install($plugin_version, &$errors=array())
{
- return $this->__call(__FUNCTION__, func_get_args());
+ if (is_callable('plugin_install'))
+ {
+ return plugin_install($this->plugin_id, $plugin_version, $errors);
+ }
}
function activate($plugin_version, &$errors=array())
{
- return $this->__call(__FUNCTION__, func_get_args());
+ if (is_callable('plugin_activate'))
+ {
+ return plugin_activate($this->plugin_id, $plugin_version, $errors);
+ }
}
function deactivate()
{
- return $this->__call(__FUNCTION__, func_get_args());
+ if (is_callable('plugin_install'))
+ {
+ return plugin_install($this->plugin_id);
+ }
}
function uninstall()
{
- return $this->__call(__FUNCTION__, func_get_args());
- }
-
- function __call($name, $arguments)
- {
- if (is_callable('plugin_'.$name))
+ if (is_callable('plugin_uninstall'))
{
- array_unshift($arguments, $this->plugin_id);
- return call_user_func_array('plugin_'.$name, $arguments);
+ return plugin_uninstall($this->plugin_id);
}
- return null;
}
}