Skip to content

Commit c141f45

Browse files
committed
fix if valueAttributes are not set
1 parent 4dae170 commit c141f45

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

adm_program/system/classes/HtmlForm.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1154,7 +1154,7 @@ public function addSelectBox(string $id, string $label, array $values, array $op
11541154
}
11551155

11561156
// if special value attributes are set then add them to the values array
1157-
if(count($optionsAll['valueAttributes']) > 0) {
1157+
if(is_array($optionsAll['valueAttributes']) && count($optionsAll['valueAttributes']) > 0) {
11581158
foreach($valuesArray as &$valueArray) {
11591159
if (isset($optionsAll['valueAttributes'][$valueArray['id']])) {
11601160
foreach($optionsAll['valueAttributes'][$valueArray['id']] as $key => $value) {

0 commit comments

Comments
 (0)