Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
ShowOutOfStockConfig.php
Go to the documentation of this file.
1 <?php
7 
9 {
14 
18  public function __construct(\Magento\Catalog\Model\Indexer\Product\Eav\Processor $eavIndexerProcessor)
19  {
20  $this->_eavIndexerProcessor = $eavIndexerProcessor;
21  }
22 
31  public function afterSave(\Magento\Framework\App\Config\Value $subject, $result)
32  {
33  if ($subject->isValueChanged()) {
34  $this->_eavIndexerProcessor->markIndexerAsInvalid();
35  }
36  return $result;
37  }
38 }
__construct(\Magento\Catalog\Model\Indexer\Product\Eav\Processor $eavIndexerProcessor)
afterSave(\Magento\Framework\App\Config\Value $subject, $result)