FIX check commande liste validate (#35479)

This commit is contained in:
atm-GregM 2025-09-25 11:57:49 +02:00 committed by GitHub
parent 6916ca7ac8
commit 35bb894393
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -781,7 +781,7 @@ if ($action == 'validate' && $permissiontoadd && $objectclass !== null) {
} else {
$idwarehouse = 0;
}
if ($objecttmp->valid($user, $idwarehouse)) {
if ($objecttmp->valid($user, $idwarehouse) > 0) {
setEventMessages($langs->trans('hasBeenValidated', $objecttmp->ref), null, 'mesgs');
} else {
setEventMessages($objecttmp->error, $objecttmp->errors, 'errors');