Skip to content
Snippets Groups Projects
Commit 0b2d3353 authored by Jan-Hendrik Willms's avatar Jan-Hendrik Willms Committed by Jan-Hendrik Willms
Browse files

failsafe studyarea assignment detection, fixes #1550

Closes #1550

Merge request studip/studip!969
parent 408e9f68
No related branches found
No related tags found
No related merge requests found
...@@ -407,7 +407,11 @@ class LVGroupsWizardStep implements CourseWizardStep ...@@ -407,7 +407,11 @@ class LVGroupsWizardStep implements CourseWizardStep
} }
} else { } else {
// optional step if study areas step is activated and at least one area is assigned // optional step if study areas step is activated and at least one area is assigned
if (!count($values[__CLASS__]['lvgruppe_selection']['areas'])) { if (
!isset($values[__CLASS__]['lvgruppe_selection']['areas'])
|| !is_array($values[__CLASS__]['lvgruppe_selection']['areas'])
|| count($values[__CLASS__]['lvgruppe_selection']['areas']) === 0
) {
$ok = false; $ok = false;
$errors[] = _('Der Veranstaltung muss mindestens eine Lehrveranstaltungsgruppe zugeordnet sein.'); $errors[] = _('Der Veranstaltung muss mindestens eine Lehrveranstaltungsgruppe zugeordnet sein.');
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment