Closed
Description
Hello!
- In method Collection::filterByProductType:
if (!is_string($typeFilter) && !is_array($typeFilter)) {
new \Magento\Framework\Exception\LocalizedException(__('The product type filter specified is incorrect.'));
}
\Magento\Framework\Exception\LocalizedException is created but not thrown.
Is "throw" keyword missing?
- In method AbstractProduct::getModel:
try {
$model = $this->_indexFactory->get($this->_indexType);
} catch (\InvalidArgumentException $e) {
new \Magento\Framework\Exception\LocalizedException(__('Index type is not valid'));
}
\Magento\Framework\Exception\LocalizedException is created but not thrown.
These possible defects found by static analyzer AppChecker