From deb57770a57c342a9f61be83c0aa2e084499255f Mon Sep 17 00:00:00 2001 From: Eric Risler Date: Wed, 30 Aug 2017 14:38:05 -0400 Subject: [PATCH] for for #19 --- .../Console/Command/RegenerateProductUrlCommand.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Iazel/RegenProductUrl/Console/Command/RegenerateProductUrlCommand.php b/Iazel/RegenProductUrl/Console/Command/RegenerateProductUrlCommand.php index 762ab21..b1ba22f 100644 --- a/Iazel/RegenProductUrl/Console/Command/RegenerateProductUrlCommand.php +++ b/Iazel/RegenProductUrl/Console/Command/RegenerateProductUrlCommand.php @@ -84,7 +84,8 @@ public function execute(InputInterface $inp, OutputInterface $out) $list = $this->collection->load(); foreach($list as $product) { - if($store_id === Store::DEFAULT_STORE_ID) + // fix for #19 - also appears to relate to https://github.com/Iazel/magento2-regenurl/pull/6/commits/179a2e21ee84d9455debf408ad751a5350d2c414 + if($store_id !== Store::DEFAULT_STORE_ID) $product->setStoreId($store_id); $this->urlPersist->deleteByData([