Issue #3251895 by Shabbir, rodrigoaguilera, ckrina: claro_form_views_ui_config_item_form_alter() assumes a suffix when there is a prefix leading to: Undefined index #suffix in $form['options']['value']

(cherry picked from commit b4263a3e42)
merge-requests/7413/head
Alex Pott 2024-04-09 11:35:03 +01:00
parent b2dc1c1010
commit cbf32be712
No known key found for this signature in database
GPG Key ID: BDA67E7EE836E5CE
1 changed files with 1 additions and 1 deletions

View File

@ -1705,7 +1705,7 @@ function claro_form_views_ui_config_item_form_alter(array &$form, FormStateInter
foreach (['views-left-30', 'views-left-40'] as $left_class) {
if (str_contains($form['options']['operator']['#prefix'], $left_class)) {
$form['options']['operator']['#prefix'] = '<div class="views-config-group-region">' . str_replace($left_class, 'views-group-box--operator', $form['options']['operator']['#prefix']);
$form['options']['value']['#suffix'] = $form['options']['value']['#suffix'] . '</div>';
$form['options']['value']['#suffix'] = ($form['options']['value']['#suffix'] ?? '') . '</div>';
}
}
}