Skip to content

Commit

Permalink
Fix: add to cart grouped product when exists a sold out option
Browse files Browse the repository at this point in the history
  • Loading branch information
gihovani committed Oct 9, 2019
1 parent 5f1a803 commit f27f749
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -344,7 +344,7 @@ protected function getProductInfo(\Magento\Framework\DataObject $buyRequest, $pr
}
foreach ($associatedProducts as $subProduct) {
if (!isset($productsInfo[$subProduct->getId()])) {
if ($isStrictProcessMode && !$subProduct->getQty()) {
if ($isStrictProcessMode && !$subProduct->getQty() && $subProduct->isSalable()) {
return __('Please specify the quantity of product(s).')->render();
}
$productsInfo[$subProduct->getId()] = $subProduct->isSalable() ? (float)$subProduct->getQty() : 0;
Expand Down

0 comments on commit f27f749

Please sign in to comment.