From 63f2e6ba1d32e28ac25c2630e5adfbf5b51d0b9c Mon Sep 17 00:00:00 2001 From: skodak Date: Sun, 21 Jan 2007 10:33:28 +0000 Subject: [PATCH] MDL-8198 Modules whose names are substrings of other chosen modules are considered chosen as well --- admin/enrol.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/admin/enrol.php b/admin/enrol.php index 3f6cfb2fdb..b90ea29a01 100644 --- a/admin/enrol.php +++ b/admin/enrol.php @@ -63,6 +63,7 @@ $table->data = array(); $modules = get_list_of_plugins("enrol"); + $enabledplugins = explode(',', $CFG->enrol_plugins_enabled); foreach ($modules as $module) { // skip if directory is empty @@ -73,7 +74,7 @@ $name = get_string("enrolname", "enrol_$module"); $plugin = enrolment_factory::factory($module); $enable = 'enrol_plugins_enabled, $module) !== false) { + if (in_array($module, $enabledplugins)) { $enable .= ' checked="checked"'; } if ($module == 'manual') { -- 2.39.5