aboutsummaryrefslogtreecommitdiff
path: root/engine/lib/views.php
diff options
context:
space:
mode:
authorcash <cash.costello@gmail.com>2011-11-05 19:15:42 -0400
committercash <cash.costello@gmail.com>2011-11-05 19:15:42 -0400
commit61d24f4b7b4fd4d5e960593a25a0d96b11891ff0 (patch)
treeaf0128a6f7a99aa92c807bcfad03341c08fd35a6 /engine/lib/views.php
parenteeade2d2716826b419c1ca67a62a102017c31b02 (diff)
downloadelgg-61d24f4b7b4fd4d5e960593a25a0d96b11891ff0.tar.gz
elgg-61d24f4b7b4fd4d5e960593a25a0d96b11891ff0.tar.bz2
Fixes #4024 fixed a lot of notices - enough for this release - found a few bugs
Diffstat (limited to 'engine/lib/views.php')
-rw-r--r--engine/lib/views.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/engine/lib/views.php b/engine/lib/views.php
index 6ca68ac8c..0f806b8be 100644
--- a/engine/lib/views.php
+++ b/engine/lib/views.php
@@ -743,7 +743,11 @@ function elgg_view_menu($menu_name, array $vars = array()) {
$sort_by = elgg_extract('sort_by', $vars, 'text');
- $menu = $CONFIG->menus[$menu_name];
+ if (isset($CONFIG->menus[$menu_name])) {
+ $menu = $CONFIG->menus[$menu_name];
+ } else {
+ $menu = array();
+ }
// Give plugins a chance to add menu items just before creation.
// This supports dynamic menus (example: user_hover).
@@ -1198,7 +1202,8 @@ function elgg_view_image_block($image, $body, $vars = array()) {
* @since 1.8.0
*/
function elgg_view_module($type, $title, $body, $vars = array()) {
- $vars['class'] .= " elgg-module-$type";
+
+ $vars['class'] = elgg_extract('class', $vars, '') . " elgg-module-$type";
$vars['title'] = $title;
$vars['body'] = $body;
return elgg_view('page/components/module', $vars);