aboutsummaryrefslogtreecommitdiff
path: root/engine/lib/navigation.php
diff options
context:
space:
mode:
authorBrett Profitt <brett.profitt@gmail.com>2011-09-29 18:16:03 -0700
committerBrett Profitt <brett.profitt@gmail.com>2011-09-29 18:16:03 -0700
commitbfdb9bb8a87a29038ba1ae25355684ae19678fdd (patch)
treea074e2d6bfa19c17b284c3950b4555cf584eabe2 /engine/lib/navigation.php
parent7be23080f34a8f92ca1f8d49c3aa0e6ce3472f4c (diff)
parenta458ae4e0f8e5b19884860fead6e5f901b95eca4 (diff)
downloadelgg-bfdb9bb8a87a29038ba1ae25355684ae19678fdd.tar.gz
elgg-bfdb9bb8a87a29038ba1ae25355684ae19678fdd.tar.bz2
Merge branch 'master' of github.com:brettp/Elgg
Diffstat (limited to 'engine/lib/navigation.php')
-rw-r--r--engine/lib/navigation.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/engine/lib/navigation.php b/engine/lib/navigation.php
index cefe40ecf..27af26be2 100644
--- a/engine/lib/navigation.php
+++ b/engine/lib/navigation.php
@@ -53,6 +53,9 @@
* 'register', 'menu:<menu_name>'. If you do, you may end up with many incorrect
* links on a context-sensitive menu.
*
+ * @warning A menu item's name must be unique per menu. If more than one menu
+ * item with the same name are registered, the last menu item takes priority.
+ *
* @see elgg_view_menu() for the plugin hooks available for modifying a menu as
* it is being rendered.
*
@@ -282,7 +285,9 @@ function elgg_site_menu_setup($hook, $type, $return, $params) {
}
$return['default'] = $featured;
- $return['more'] = $registered;
+ if (count($registered) > 0) {
+ $return['more'] = $registered;
+ }
} else {
// no featured menu items set
$max_display_items = 5;