[-] BO : fix #PSCFV-3243
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@16474 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
1 parent
0c0fa767b5
commit
b8184785d1
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