From 508db412a8b8ff6e235132276bd5169a945fd8e9 Mon Sep 17 00:00:00 2001 From: eileen Date: Sun, 8 Mar 2020 21:55:36 +1300 Subject: [PATCH] Remove an instance of passing non-arraay to CRM_Utils_Array::value( --- CRM/Core/Menu.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/CRM/Core/Menu.php b/CRM/Core/Menu.php index 9b767aeb97..f481131cc0 100644 --- a/CRM/Core/Menu.php +++ b/CRM/Core/Menu.php @@ -502,6 +502,8 @@ class CRM_Core_Menu { /** * @param $menu * @param $path + * + * @throws \CRM_Core_Exception */ public static function fillComponentIds(&$menu, $path) { static $cache = array(); @@ -525,7 +527,7 @@ class CRM_Core_Menu { $menu[$path]['component_id'] = $cache[$compPath]; } else { - if (CRM_Utils_Array::value('component', CRM_Utils_Array::value($compPath, $menu))) { + if (!empty($menu[$compPath]['component'])) { $componentId = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_Component', $menu[$compPath]['component'], 'id', 'name' -- 2.25.1