[-] BO : fix #PSCFV-3243
This commit is contained in:
1 parent
516b555397
commit
c7b28f2a42
1 file changed
+4
-6
@@ -1443,11 +1443,6 @@ class AdminImportControllerCore extends AdminController
|
|||||||
$product->deleteImages();
|
$product->deleteImages();
|
||||||
$this->cache_image_deleted[(int)$product->id] = true;
|
$this->cache_image_deleted[(int)$product->id] = true;
|
||||||
}
|
}
|
||||||
else if (array_key_exists('image_url', $info) && !isset($this->cache_image_deleted[(int)$product->id]))
|
|
||||||
{
|
|
||||||
$product->deleteImages();
|
|
||||||
$this->cache_image_deleted[(int)$product->id] = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (isset($info['image_url']) && $info['image_url'])
|
if (isset($info['image_url']) && $info['image_url'])
|
||||||
{
|
{
|
||||||
@@ -1466,7 +1461,10 @@ class AdminImportControllerCore extends AdminController
|
|||||||
{
|
{
|
||||||
$image->associateTo($id_shop_list);
|
$image->associateTo($id_shop_list);
|
||||||
if (!AdminImportController::copyImg($product->id, $image->id, $url))
|
if (!AdminImportController::copyImg($product->id, $image->id, $url))
|
||||||
$this->warnings[] = Tools::displayError('Error copying image:').$url;
|
{
|
||||||
|
$this->warnings[] = sprintf(Tools::displayError('Error copying image: %s'), $url);
|
||||||
|
$image->delete();
|
||||||
|
}
|
||||||
else
|
else
|
||||||
$id_image = array($image->id);
|
$id_image = array($image->id);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user