From 4801117c374b0fa6c5fe8ac3bf95b8a0df7553c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20FRANCE?= Date: Fri, 21 Feb 2020 09:24:24 +0100 Subject: [PATCH] avoid warning if not an array --- htdocs/projet/element.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/projet/element.php b/htdocs/projet/element.php index f944114e43c..f95c0b147b4 100644 --- a/htdocs/projet/element.php +++ b/htdocs/projet/element.php @@ -620,7 +620,7 @@ foreach ($listofreferent as $key => $value) $elementarray = $object->get_element_list($key, $tablename, $datefieldname, $dates, $datee, !empty($project_field) ? $project_field : 'fk_projet'); - if (count($elementarray) > 0 && is_array($elementarray)) + if (is_array($elementarray) && count($elementarray) > 0) { $total_ht = 0; $total_ttc = 0;