Commit 506c80bd authored by Steven Wittens's avatar Steven Wittens
Browse files

#58568: Multiple profile selection boxes repeat items

parent 027f9836
......@@ -660,9 +660,7 @@ function profile_form_profile($edit, $user, $category) {
);
break;
case 'selection':
if (!$field->required) {
$options = array('--');
}
$options = $field->required ? array() : array('--');
$lines = split("[,\n\r]", $field->options);
foreach ($lines as $line) {
if ($line = trim($line)) {
......
......@@ -660,9 +660,7 @@ function profile_form_profile($edit, $user, $category) {
);
break;
case 'selection':
if (!$field->required) {
$options = array('--');
}
$options = $field->required ? array() : array('--');
$lines = split("[,\n\r]", $field->options);
foreach ($lines as $line) {
if ($line = trim($line)) {
......
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