mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-08-22 23:05:18 -04:00
Correct the "inappropriate intimacy" smell that bharat's refined senses pick up
This commit is contained in:
@@ -69,23 +69,10 @@ class Admin_View_Core extends View {
|
||||
}
|
||||
}
|
||||
|
||||
$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);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Print out any site wide status information.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user