We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 25cf0c3 commit d95ffa1Copy full SHA for d95ffa1
app/code/Magento/CatalogUrlRewrite/Observer/AfterImportDataObserver.php
@@ -157,7 +157,11 @@ public function execute(Observer $observer)
157
protected function _populateForUrlGeneration($rowData)
158
{
159
$newSku = $this->import->getNewSku($rowData[ImportProduct::COL_SKU]);
160
- if (empty($newSku) || !isset($newSku['entity_id']) || empty($rowData[self::URL_KEY_ATTRIBUTE_CODE])) {
+ if (empty($newSku) || !isset($newSku['entity_id'])) {
161
+ return null;
162
+ }
163
+ if ($this->import->getRowScope($rowData) == ImportProduct::SCOPE_STORE
164
+ && empty($rowData[self::URL_KEY_ATTRIBUTE_CODE])) {
165
return null;
166
}
167
$rowData['entity_id'] = $newSku['entity_id'];
0 commit comments