mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-07-14 11:00:11 -04:00
Sort the Admin > Settings menu instead of relying on module activation order.
Requires making Menu::get() return a reference. Fixes #1545.
This commit is contained in:
@@ -44,6 +44,10 @@ class Admin_View_Core extends Gallery_View {
|
||||
public function admin_menu() {
|
||||
$menu = Menu::factory("root");
|
||||
module::event("admin_menu", $menu, $this);
|
||||
|
||||
$settings_menu = $menu->get("settings_menu");
|
||||
sort($settings_menu->elements);
|
||||
|
||||
return $menu->render();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user