// Fix duplication of images
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@11395 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -236,6 +236,7 @@ class ImageCore extends ObjectModel
|
||||
{
|
||||
$image_old = new Image($row['id_image']);
|
||||
$image_new = clone $image_old;
|
||||
unset($image_new->id);
|
||||
$image_new->id_product = (int)$id_product_new;
|
||||
// A new id is generated for the cloned image when calling add()
|
||||
if ($image_new->add())
|
||||
|
||||
Reference in New Issue
Block a user