1
0
mirror of https://github.com/e107inc/e107.git synced 2025-01-17 04:38:27 +01:00

Prevent looping of non-existent array.

This commit is contained in:
Cameron 2021-08-12 11:53:40 -07:00
parent 32618817d1
commit 0c30006b5f

View File

@ -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 = "<div id='l_".$id."' class='menu' onmouseover=\"menuMouseover(event)\">";
foreach ($linklist['sub_'.$id] as $sub)
{
// Filter title for backwards compatibility ---->