From b8b5b97d78e10d159ccb1538d300c91221fa8dbd Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 9 Sep 2021 19:47:15 +0200 Subject: [PATCH] Code comment --- htdocs/holiday/class/holiday.class.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/holiday/class/holiday.class.php b/htdocs/holiday/class/holiday.class.php index 95462ddd77e..5ecc4d7325a 100644 --- a/htdocs/holiday/class/holiday.class.php +++ b/htdocs/holiday/class/holiday.class.php @@ -714,12 +714,12 @@ class Holiday extends CommonObject // Update status $sql = "UPDATE ".MAIN_DB_PREFIX."holiday SET"; if (!empty($this->statut) && is_numeric($this->statut)) { - $sql .= " statut = ".$this->statut.","; + $sql .= " statut = ".((int) $this->statut).","; } else { $error++; } $sql .= " ref = '".$this->db->escape($num)."'"; - $sql .= " WHERE rowid= ".$this->id; + $sql .= " WHERE rowid= ".((int) $this->id); $this->db->begin(); @@ -1937,7 +1937,7 @@ class Holiday extends CommonObject * * @param int $fk_user_action Id user creation * @param int $fk_user_update Id user update - * @param string $label Label + * @param string $label Label (Example: 'Leave', 'Manual update', 'Leave request cancelation'...) * @param int $new_solde New value * @param int $fk_type Type of vacation * @return int Id of record added, 0 if nothing done, < 0 if KO