mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-01-21 16:23:20 +01:00
FIX: #14474 Error when deleting
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
* Copyright (C) 2004-2012 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2014 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2006 Andre Cianfarani <acianfa@free.fr>
|
||||
* Copyright (C) 2010-2016 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2010-2020 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2011 Jean Heimburger <jean@tiaris.info>
|
||||
* Copyright (C) 2012-2014 Christophe Battarel <christophe.battarel@altairis.fr>
|
||||
* Copyright (C) 2012 Cedric Salvador <csalvador@gpcsolutions.fr>
|
||||
@@ -3327,6 +3327,11 @@ class Commande extends CommonOrder
|
||||
|
||||
if (! $error)
|
||||
{
|
||||
// On delete ecm_files database info
|
||||
if (!$this->delete_ecmfiles()) {
|
||||
$this->db->rollback();
|
||||
return 0;
|
||||
}
|
||||
// Remove directory with files
|
||||
$comref = dol_sanitizeFileName($this->ref);
|
||||
if ($conf->commande->dir_output && !empty($this->ref))
|
||||
|
||||
Reference in New Issue
Block a user