Verified Commit 2d7f4046 authored by Côme Chilliet's avatar Côme Chilliet
Browse files

:ambulance: fix(supann) Avoid PHP crash when LDAP contains invalid data

If supannEtuCursusAnnee contains invalid data, do not crash.

issue #6015
No related merge requests found
Showing with 1 addition and 1 deletion
+1 -1
......@@ -55,6 +55,6 @@ class SupannCursusAnneeAttribute extends SupannPrefixedSelectAttribute
protected function supannUpdateSelect ()
{
$prefix = $this->attributes[0]->getValue();
$this->attributes[1]->setChoices($this->prefixedChoices[$prefix][0], $this->prefixedChoices[$prefix][1]);
$this->attributes[1]->setChoices($this->prefixedChoices[$prefix][0] ?? [], $this->prefixedChoices[$prefix][1] ?? []);
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment