From 5578151badd69eba8a1803aa41d224b560271fac Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Thu, 7 May 2015 11:59:45 +0200 Subject: [PATCH] Fix: add $object for use with triggers --- htdocs/product/class/product.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/product/class/product.class.php b/htdocs/product/class/product.class.php index 979c1a935f9..a0ade451c53 100644 --- a/htdocs/product/class/product.class.php +++ b/htdocs/product/class/product.class.php @@ -1,7 +1,7 @@ * Copyright (C) 2004-2014 Laurent Destailleur - * Copyright (C) 2005-2014 Regis Houssin + * Copyright (C) 2005-2015 Regis Houssin * Copyright (C) 2006 Andre Cianfarani * Copyright (C) 2007-2011 Jean Heimburger * Copyright (C) 2010-2013 Juanjo Menent @@ -3437,7 +3437,7 @@ class Product extends CommonObject $filename = preg_replace('/'.preg_quote($dir,'/').'/i','',$file); // Nom du fichier // On efface l'image d'origine - dol_delete_file($file); + dol_delete_file($file, 0, 0, 0, $this); // For triggers // Si elle existe, on efface la vignette if (preg_match('/('.$this->regeximgext.')$/i',$filename,$regs))