Fix warning in PHP 7.1 when using undefined array index - refs BT#12571

remotes/angel/1.11.x
Yannick Warnier 8 years ago
parent 122be161c1
commit 0f6208345d
  1. 3
      main/inc/lib/pear/HTML/QuickForm/select.php

@ -77,6 +77,9 @@ class HTML_QuickForm_select extends HTML_QuickForm_element
if (!empty($attributes['class'])) {
$oldClass = $attributes['class'];
}
if (empty($attributes)) {
$attributes = []; // Initialize variable to avoid warning in PHP 7.1
}
$attributes['class'] = $oldClass . ' selectpicker show-tick form-control';
$attributes['data-live-search'] = 'true';

Loading…
Cancel
Save