/** * @SuppressWarnings(PHPMD.CamelCaseMethodName) * @SuppressWarnings(PHPMD.ElseExpression) * * {@inheritDoc} */ protected function _prepareValueOptions() { $selectReady = $this->getData('value_select_options'); $hashedReady = $this->getData('value_option'); if (in_array($this->getAttribute(), ['stock.is_in_stock', 'has_image', 'price.is_discount'])) { $selectOptions = $this->booleanSource->toOptionArray(); $this->_setSelectOptions($selectOptions, $selectReady, $hashedReady); } else { parent::_prepareValueOptions(); } }