From a6a9b256ae7ac686ed1f53c05275ae702fb37aad Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Wed, 17 Jun 2009 13:34:18 -0700 Subject: Correct the "inappropriate intimacy" smell that bharat's refined senses pick up --- modules/gallery/libraries/Theme_View.php | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'modules/gallery/libraries/Theme_View.php') diff --git a/modules/gallery/libraries/Theme_View.php b/modules/gallery/libraries/Theme_View.php index 904a3c07..7b2ca840 100644 --- a/modules/gallery/libraries/Theme_View.php +++ b/modules/gallery/libraries/Theme_View.php @@ -103,25 +103,12 @@ class Theme_View_Core extends View { call_user_func_array(array($class, "site"), array(&$menu, $this)); } } - - $this->_remove_empty_items($menu); } + $menu->compact(); print $menu; } - private function _remove_empty_items($menu) { - foreach ($menu->elements as $target_id => $element) { - if ($element->type == "submenu") { - if (empty($element->elements)) { - $menu->remove($target_id); - } else { - $this->_remove_empty_items($element); - } - } - } - } - public function album_menu() { $this->_menu("album"); } -- cgit v1.2.3