Skip to content

Commit

Permalink
[task] #91. Fix ExecuteFull (clean Replica Table)
Browse files Browse the repository at this point in the history
  • Loading branch information
maghamed committed Oct 1, 2017
1 parent e0feec6 commit 455d840
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions app/code/Magento/Inventory/Indexer/StockItem/StockItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,8 @@ public function executeFull()
->setAlias(Alias::ALIAS_MAIN)
->build();

if (!$this->indexStructure->isExist($replicaIndexName, ResourceConnection::DEFAULT_CONNECTION)) {
$this->indexStructure->create($replicaIndexName, ResourceConnection::DEFAULT_CONNECTION);
}
$this->indexStructure->delete($replicaIndexName, ResourceConnection::DEFAULT_CONNECTION);
$this->indexStructure->create($replicaIndexName, ResourceConnection::DEFAULT_CONNECTION);

if (!$this->indexStructure->isExist($mainIndexName, ResourceConnection::DEFAULT_CONNECTION)) {
$this->indexStructure->create($mainIndexName, ResourceConnection::DEFAULT_CONNECTION);
Expand Down

0 comments on commit 455d840

Please sign in to comment.