set errors from object

This commit is contained in:
Frédéric FRANCE 2023-02-24 16:55:26 +01:00
parent 2d454d6815
commit e4e472b4ff

View File

@ -1175,8 +1175,7 @@ class SupplierProposal extends CommonObject
$action = '';
$reshook = $hookmanager->executeHooks('createFrom', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks
if ($reshook < 0) {
$this->errors += $hookmanager->errors;
$this->error = $hookmanager->error;
$this->setErrorsFromObject($hookmanager);
$error++;
}
}