Skip to content

Commit 73a3438

Browse files
author
Stanislav Idolov
authored
ENGCOM-1944: Use correct error message for duplicate error key in product import #15980
2 parents ea666af + 474385a commit 73a3438

File tree

1 file changed

+6
-1
lines changed
  • app/code/Magento/CatalogImportExport/Model/Import

1 file changed

+6
-1
lines changed

app/code/Magento/CatalogImportExport/Model/Import/Product.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2715,7 +2715,12 @@ protected function checkUrlKeyDuplicates()
27152715
);
27162716
foreach ($urlKeyDuplicates as $entityData) {
27172717
$rowNum = $this->rowNumbers[$entityData['store_id']][$entityData['request_path']];
2718-
$this->addRowError(ValidatorInterface::ERROR_DUPLICATE_URL_KEY, $rowNum);
2718+
$message = sprintf(
2719+
$this->retrieveMessageTemplate(ValidatorInterface::ERROR_DUPLICATE_URL_KEY),
2720+
$entityData['request_path'],
2721+
$entityData['sku']
2722+
);
2723+
$this->addRowError(ValidatorInterface::ERROR_DUPLICATE_URL_KEY, $rowNum, 'url_key', $message);
27192724
}
27202725
}
27212726
}

0 commit comments

Comments
 (0)