summaryrefslogtreecommitdiff
path: root/classes/pluginhandler.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2019-08-16 15:29:24 +0300
committerAndrew Dolgov <[email protected]>2019-08-16 15:29:24 +0300
commit3e4701116d9a7a2b93646f2c9aed80b63175d206 (patch)
tree76a6d8664cb7ff9b7bbb2e6da5b3ee434baca59f /classes/pluginhandler.php
parent865c54abcb5bdfb6d68757cfadccd8383cdc213c (diff)
af_readability: add missing file
Diffstat (limited to 'classes/pluginhandler.php')
-rw-r--r--classes/pluginhandler.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/classes/pluginhandler.php b/classes/pluginhandler.php
index d10343e09..9682e440f 100644
--- a/classes/pluginhandler.php
+++ b/classes/pluginhandler.php
@@ -5,15 +5,18 @@ class PluginHandler extends Handler_Protected {
}
function catchall($method) {
- $plugin = PluginHost::getInstance()->get_plugin(clean($_REQUEST["plugin"]));
+ $plugin_name = clean($_REQUEST["plugin"]);
+ $plugin = PluginHost::getInstance()->get_plugin($plugin_name);
if ($plugin) {
if (method_exists($plugin, $method)) {
$plugin->$method();
} else {
+ user_error("PluginHandler: Requested unknown method '$method' of plugin '$plugin_name'.", E_USER_WARNING);
print error_json(13);
}
} else {
+ user_error("PluginHandler: Requested method '$method' of unknown plugin '$plugin_name'.", E_USER_WARNING);
print error_json(14);
}
}