Skip to content

Commit

Permalink
Fixed multiple checkboxes mistakenly marked as required if a Field is…
Browse files Browse the repository at this point in the history
… marked as required. (#1312)

Co-authored-by: richardgaunt <[email protected]>
  • Loading branch information
AlexSkrypnyk and richardgaunt authored Oct 22, 2024
1 parent 4c4afb9 commit 7f08556
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions web/themes/contrib/civictheme/includes/form_element.inc
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,8 @@ function civictheme_preprocess_fieldset__form_element__civictheme_field__checkbo
'id' => Html::cleanCssIdentifier($element['#id'] . '-' . $value),
'is_checked' => is_array($element['#default_value']) ? in_array($value, $element['#default_value']) : $element['#default_value'] == $value,
'is_disabled' => isset($element['#attributes']['disabled']),
// Checkboxes controls with a group cannot be required by definition.
'is_required' => FALSE,
'attributes' => $attributes,
'modifier_class' => $modifier_class,
];
Expand Down

0 comments on commit 7f08556

Please sign in to comment.