From 0c30006b5fa485f9b082c4eba24bda636b96f637 Mon Sep 17 00:00:00 2001 From: Cameron Date: Thu, 12 Aug 2021 11:53:40 -0700 Subject: [PATCH] Prevent looping of non-existent array. --- e107_core/shortcodes/single/sitelinks_alt.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/e107_core/shortcodes/single/sitelinks_alt.php b/e107_core/shortcodes/single/sitelinks_alt.php index 4cbc75b9a..56278e28d 100644 --- a/e107_core/shortcodes/single/sitelinks_alt.php +++ b/e107_core/shortcodes/single/sitelinks_alt.php @@ -184,8 +184,15 @@ class sitelinks_alt static function render_sub($linklist, $id, $params, $icon) { $tp = e107::getParser(); + + if(!isset($linklist['sub_'.$id]) || !is_array($linklist['sub_'.$id])) + { + return null; + } $text = "