Commit 5206daaf authored by Gábor Hojtsy's avatar Gábor Hojtsy

#177529 by chx: if no checkbox was selected, we still need an empty array()

parent 206d652a
......@@ -1028,7 +1028,7 @@ function form_type_checkbox_value($form, $edit = FALSE) {
* The data that will appear in the $form_state['values'] collection
* for this element. Return nothing to use the default.
*/
function form_type_checkboxes_value($form, $edit = FALSE) {
function form_type_checkboxes_value($form, $edit = FALSE) {
if ($edit === FALSE) {
$value = array();
$form += array('#default_value' => array());
......@@ -1037,6 +1037,9 @@ function form_type_checkboxes_value($form, $edit = FALSE) {
}
return $value;
}
elseif (!isset($edit)) {
return array();
}
}
/**
......
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