diff --git a/lib/components/form/element/combobox.js b/lib/components/form/element/combobox.js index 2740dd77..ae482a59 100644 --- a/lib/components/form/element/combobox.js +++ b/lib/components/form/element/combobox.js @@ -485,7 +485,7 @@ class Combobox extends React.Component { const formatOption = (option) => ({ focused: false, - isSelected: option.selected && (isEqual(option.value, currentValue) || !!(alreadySelected.find((item) => item.value === option.value))), + isSelected: option.selected && (isEqual(option.value, currentValue) || !!alreadySelected.find((item) => item.value === option.value)), ...option, }); @@ -551,7 +551,7 @@ class Combobox extends React.Component { const deselectOption = (initialOption) => { const option = initialOption; const isSelected = isEqual(option.value, val); - option.isSelected = isSelected || !!(this.props.alreadySelectedOptions.find((optionItem) => optionItem.value === option.value)); + option.isSelected = isSelected || !!this.props.alreadySelectedOptions.find((optionItem) => optionItem.value === option.value); return option; }; @@ -859,8 +859,7 @@ class Combobox extends React.Component { const formatOption = (option) => ({ focused: false, isSelected: - isEqual(option.value ? option.value.toUpperCase : '', value.toUpperCase()) || - !!(this.props.alreadySelectedOptions.find((optionItem) => optionItem.value === option.value)), + isEqual(option.value ? option.value.toUpperCase : '', value.toUpperCase()) || !!this.props.alreadySelectedOptions.find((optionItem) => optionItem.value === option.value), ...option, });