From: Evan Prodromou Date: Tue, 23 Aug 2011 03:53:34 +0000 (-0400) Subject: avoid producing notices for last element in MoreMenu X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=5e61ec5e01c8f6633f74968939f8fa6875dd32f7;p=quix0rs-gnu-social.git avoid producing notices for last element in MoreMenu --- diff --git a/lib/moremenu.php b/lib/moremenu.php index fa335b3c7b..8aed58a921 100644 --- a/lib/moremenu.php +++ b/lib/moremenu.php @@ -81,7 +81,12 @@ class MoreMenu extends Menu } foreach ($toShow as $item) { - list($actionName, $args, $label, $description, $id) = $item; + if (count($item) == 5) { + list($actionName, $args, $label, $description, $id) = $item; + } else { + list($actionName, $args, $label, $description) = $item; + $id = null; + } $this->item($actionName, $args, $label, $description, $id); }