From 8485a1ea041f53a781e4180e40738e7b844870b4 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Mon, 11 Oct 2021 12:43:20 +0200 Subject: [PATCH] fix PHP 8.0 TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given --- importexport/inc/class.importexport_export_csv.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/importexport/inc/class.importexport_export_csv.inc.php b/importexport/inc/class.importexport_export_csv.inc.php index 5135916fbd..aa1cdaa7e1 100644 --- a/importexport/inc/class.importexport_export_csv.inc.php +++ b/importexport/inc/class.importexport_export_csv.inc.php @@ -279,7 +279,7 @@ class importexport_export_csv implements importexport_iface_export_record } // Fall through for other settings case 'select': - if (count($c_field['values']) == 1 && isset($c_field['values']['@'])) + if (!empty($c_field['values']) && count($c_field['values']) == 1 && isset($c_field['values']['@'])) { $c_field['values'] = Api\Storage\Customfields::get_options_from_file($c_field['values']['@']); }