mirror of
https://github.com/moodle/moodle.git
synced 2025-07-16 11:56:31 +02:00
MDL-8198 Modules whose names are substrings of other chosen modules are considered chosen as well
This commit is contained in:
@ -63,6 +63,7 @@
|
|||||||
$table->data = array();
|
$table->data = array();
|
||||||
|
|
||||||
$modules = get_list_of_plugins("enrol");
|
$modules = get_list_of_plugins("enrol");
|
||||||
|
$enabledplugins = explode(',', $CFG->enrol_plugins_enabled);
|
||||||
foreach ($modules as $module) {
|
foreach ($modules as $module) {
|
||||||
|
|
||||||
// skip if directory is empty
|
// skip if directory is empty
|
||||||
@ -73,7 +74,7 @@
|
|||||||
$name = get_string("enrolname", "enrol_$module");
|
$name = get_string("enrolname", "enrol_$module");
|
||||||
$plugin = enrolment_factory::factory($module);
|
$plugin = enrolment_factory::factory($module);
|
||||||
$enable = '<input type="checkbox" name="enable[]" value="'.$module.'"';
|
$enable = '<input type="checkbox" name="enable[]" value="'.$module.'"';
|
||||||
if (stristr($CFG->enrol_plugins_enabled, $module) !== false) {
|
if (in_array($module, $enabledplugins)) {
|
||||||
$enable .= ' checked="checked"';
|
$enable .= ' checked="checked"';
|
||||||
}
|
}
|
||||||
if ($module == 'manual') {
|
if ($module == 'manual') {
|
||||||
|
Reference in New Issue
Block a user