Fix warning

This commit is contained in:
Laurent Destailleur 2020-11-09 09:55:32 +01:00
parent 807d3b99c9
commit 5d5bbb2b5e

View File

@ -844,7 +844,7 @@ class InterfaceActionsAuto extends DolibarrTriggers
$ret = $actioncomm->create($user); // User creating action
if ($ret > 0 && $conf->global->MAIN_COPY_FILE_IN_EVENT_AUTO) {
if ($ret > 0 && !empty($conf->global->MAIN_COPY_FILE_IN_EVENT_AUTO)) {
if (is_array($object->attachedfiles) && array_key_exists('paths', $object->attachedfiles) && count($object->attachedfiles['paths']) > 0) {
foreach ($object->attachedfiles['paths'] as $key=>$filespath) {
$srcfile = $filespath;