From 1d8c7f934f7d011711da4eb3aac8033f7a74458f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20FRANCE?= Date: Thu, 27 Apr 2023 09:47:00 +0200 Subject: [PATCH] clean code --- htdocs/bom/class/bom.class.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/bom/class/bom.class.php b/htdocs/bom/class/bom.class.php index a1a7ced7caf..b9d485820a5 100644 --- a/htdocs/bom/class/bom.class.php +++ b/htdocs/bom/class/bom.class.php @@ -652,7 +652,7 @@ class BOM extends CommonObject $this->db->commit(); return $result; } else { - $this->error = $line->error; + $this->setErrorsFromObject($line); dol_syslog(get_class($this)."::addLine error=".$this->error, LOG_ERR); $this->db->rollback(); return -2; @@ -764,7 +764,7 @@ class BOM extends CommonObject $this->db->commit(); return $result; } else { - $this->error = $line->error; + $this->setErrorsFromObject($line); dol_syslog(get_class($this)."::addLine error=".$this->error, LOG_ERR); $this->db->rollback(); return -2; @@ -816,7 +816,7 @@ class BOM extends CommonObject $this->db->commit(); return $result; } else { - $this->error = $line->error; + $this->setErrorsFromObject($line); dol_syslog(get_class($this)."::addLine error=".$this->error, LOG_ERR); $this->db->rollback(); return -2;