From 1650fe9ef82c921e02f20140609911926c861f7e Mon Sep 17 00:00:00 2001 From: Francis Appels Date: Fri, 11 Nov 2022 11:35:11 +0100 Subject: [PATCH 1/2] Fix warning in reception list third-party type --- htdocs/reception/list.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/htdocs/reception/list.php b/htdocs/reception/list.php index 58df4aaaa70..0f52e3e4277 100644 --- a/htdocs/reception/list.php +++ b/htdocs/reception/list.php @@ -1119,10 +1119,12 @@ while ($i < min($num, $limit)) { // Type ent if (!empty($arrayfields['typent.code']['checked'])) { print ''; - if (count($typenArray) == 0) { + if (!isset($typenArray)) { $typenArray = $formcompany->typent_array(1); } - print $typenArray[$obj->typent_code]; + if (isset($typenArray[$obj->typent_code])) { + print $typenArray[$obj->typent_code]; + } print ''; if (!$i) { $totalarray['nbfield']++; From f3938a41a5395ea9cf0541215a5af5f09064a408 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 12 Nov 2022 12:07:51 +0100 Subject: [PATCH 2/2] Update list.php --- htdocs/reception/list.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/reception/list.php b/htdocs/reception/list.php index 0f52e3e4277..210f068af0a 100644 --- a/htdocs/reception/list.php +++ b/htdocs/reception/list.php @@ -1119,7 +1119,7 @@ while ($i < min($num, $limit)) { // Type ent if (!empty($arrayfields['typent.code']['checked'])) { print ''; - if (!isset($typenArray)) { + if (!isset($typenArray) || empty($typenArray)) { $typenArray = $formcompany->typent_array(1); } if (isset($typenArray[$obj->typent_code])) {