]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
avoid producing notices for last element in MoreMenu
authorEvan Prodromou <evan@status.net>
Tue, 23 Aug 2011 03:53:34 +0000 (23:53 -0400)
committerEvan Prodromou <evan@status.net>
Tue, 23 Aug 2011 03:53:34 +0000 (23:53 -0400)
lib/moremenu.php

index fa335b3c7b7dda1b712af7c8d615290ad6fe6040..8aed58a921aadbf57b6f8383e25a677880773888 100644 (file)
@@ -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);
             }