Skip to content

Commit 2d6fb62

Browse files
committed
[TASK] Updated according to Codacy/PR Quality Review
1 parent c6196d7 commit 2d6fb62

File tree

1 file changed

+3
-3
lines changed
  • app/code/Magento/Catalog/Model/Indexer/Product/Flat/Action

1 file changed

+3
-3
lines changed

app/code/Magento/Catalog/Model/Indexer/Product/Flat/Action/Row.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ public function __construct(
6161
* @param int|null $id
6262
* @return \Magento\Catalog\Model\Indexer\Product\Flat\Action\Row
6363
* @throws \Magento\Framework\Exception\LocalizedException
64+
* @throws \Zend_Db_Statement_Exception
6465
*/
6566
public function execute($id = null)
6667
{
@@ -109,11 +110,10 @@ public function execute($id = null)
109110
}
110111
$this->flatItemWriter->write($store->getId(), $ids[0], $this->_valueFieldSuffix);
111112
}
112-
} else {
113+
}
114+
if ($status['value'] == \Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_DISABLED) {
113115
$this->flatItemEraser->deleteProductsFromStore($id, $store->getId());
114116
}
115-
116-
117117
}
118118
return $this;
119119
}

0 commit comments

Comments
 (0)