From b8d15d50f13b7ce9bf2749298a7fbe9e198e41e7 Mon Sep 17 00:00:00 2001 From: evarisk-micka Date: Wed, 3 Apr 2024 09:32:32 +0200 Subject: [PATCH] #898 [Lib] fix: saturne_get_object_metadata should not replace filled var with empty space --- lib/object.lib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/object.lib.php b/lib/object.lib.php index 35059101..c44174d3 100644 --- a/lib/object.lib.php +++ b/lib/object.lib.php @@ -664,7 +664,7 @@ function saturne_get_objects_metadata(string $type = ''): array if (!empty($objectMetadata['langfile'])) { $langs->load($objectMetadata['langfile']); } - if (dol_strlen($type) > 0) { + if (dol_strlen($type) > 0 && empty($otherNameType)) { $otherNameType = (!empty(array_search($type, $objectMetadata)) ? $objectType : ''); } }