Commit 88a9294c authored by Richard Mansfield's avatar Richard Mansfield
Browse files

Ignore event subscriptions from inactive plugins (bug #742111)


Signed-off-by: default avatarRichard Mansfield <richard.mansfield@catalyst.net.nz>
parent 05ec7802
......@@ -1274,7 +1274,11 @@ function handle_event($event, $data) {
$plugintypes = plugin_types_installed();
foreach ($plugintypes as $name) {
if ($subs = get_records_array($name . '_event_subscription', 'event', $event)) {
$pluginsinstalled = plugins_installed($name);
foreach ($subs as $sub) {
if (!isset($pluginsinstalled[$sub->plugin])) {
continue;
}
safe_require($name, $sub->plugin);
$classname = 'Plugin' . ucfirst($name) . ucfirst($sub->plugin);
try {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment