From 67fee8bc1f0724b7f5519b135ae65efbe4760001 Mon Sep 17 00:00:00 2001 From: Sukhwinder Dhillon Date: Wed, 29 May 2024 14:55:45 +0200 Subject: [PATCH] ObjectsRendererHook: Fix false positive condition --- library/Notifications/Hook/ObjectsRendererHook.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library/Notifications/Hook/ObjectsRendererHook.php b/library/Notifications/Hook/ObjectsRendererHook.php index c091c14c..5d0af3ff 100644 --- a/library/Notifications/Hook/ObjectsRendererHook.php +++ b/library/Notifications/Hook/ObjectsRendererHook.php @@ -156,8 +156,8 @@ function ($object) { foreach ($objectNamesFromSource as $objectIdTag => $objectName) { foreach ($idTagToObjectIdMap[$source] as $key => $val) { $diff = array_intersect_assoc($val[1], $objectIdTag); - if (count($diff) === count($val[1])) { - unset($idTagToObjectIdMap[$key]); + if (count($diff) === count($val[1]) && count($diff) === count($objectIdTag)) { + unset($idTagToObjectIdMap[$source][$key]); if ($asHtml) { $objectName = HtmlElement::create(