From: skodak Date: Tue, 1 Sep 2009 08:46:16 +0000 (+0000) Subject: MDL-20196 improved plugin_supports() for all plugin types X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=0db7ba95772a288e11f28259f66b1d2a4fcd8053;p=moodle.git MDL-20196 improved plugin_supports() for all plugin types --- diff --git a/lib/moodlelib.php b/lib/moodlelib.php index ab95098011..abede6ec96 100644 --- a/lib/moodlelib.php +++ b/lib/moodlelib.php @@ -6988,6 +6988,10 @@ function plugin_supports($type, $name, $feature, $default=null) { $function = $name.'_supports'; } else { + if ($feature == FEATURE_MOD_SUBPLUGINS) { + //sorry only modules + return false; + } if (!$dir = get_plugin_directory($type, $name)) { throw new coding_exception("Unsupported plugin type or name ($type/$name)"); }