mirror of
https://github.com/moodle/moodle.git
synced 2025-04-14 13:02:07 +02:00
MDL-32592 enrol_imsenterprise: fix error when category not defined
thanks to Henrik Thorn for the fix
This commit is contained in:
parent
7f3836d15a
commit
9977220ae8
@ -400,7 +400,7 @@ function process_group_tag($tagcontents) {
|
||||
// Insert default names for teachers/students, from the current language
|
||||
|
||||
// Handle course categorisation (taken from the group.org.orgunit field if present)
|
||||
if (strlen($group->category)>0) {
|
||||
if (!empty($group->category)) {
|
||||
// If the category is defined and exists in Moodle, we want to store it in that one
|
||||
if ($catid = $DB->get_field('course_categories', 'id', array('name'=>$group->category))) {
|
||||
$course->category = $catid;
|
||||
|
Loading…
x
Reference in New Issue
Block a user