MDL-75308 task: explicit check for tasks of disabled plugins.

The enabled state of a plugin is a tri-state value (boolean or
null). We should be consistent with elsewhere by only considering
boolean false as an actually disabled plugin.

See also cdcb53a1 for similar change in task management.
This commit is contained in:
Paul Holden
2022-08-30 13:04:06 +01:00
parent 952d9e9f18
commit 91ae2c25b4
2 changed files with 3 additions and 4 deletions
+1 -1
View File
@@ -254,7 +254,7 @@ abstract class task_base {
return true;
} else {
$plugininfo = core_plugin_manager::instance()->get_plugin_info($component);
return $plugininfo && $plugininfo->is_enabled();
return $plugininfo && ($plugininfo->is_enabled() !== false);
}
}
}