🚑 fix(SelectAttribute) Remove buggy code in constructor

The same thing is done better in setChoices just after.

issue #6079
parent 9e356100
......@@ -50,9 +50,6 @@ class SelectAttribute extends Attribute
*/
function __construct ($label, $description, $ldapName, $required = FALSE, $choices = [], $defaultValue = "", $outputs = NULL, $acl = "")
{
if (!in_array($defaultValue, $choices, TRUE) && isset($choices[0])) {
$defaultValue = $choices[0];
}
parent::__construct($label, $description, $ldapName, $required, $defaultValue, $acl);
$this->setChoices($choices, $outputs);
}
......
Markdown is supported
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