File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -486,6 +486,7 @@ protected function loadMenus()
486486 if (!is_object ($ menusitemsHandler ) && class_exists ('XoopsMenusItemsHandler ' )) {
487487 $ menusitemsHandler = new XoopsMenusItemsHandler ($ GLOBALS ['xoopsDB ' ]);
488488 }
489+ include_once $ GLOBALS ['xoops ' ]->path ('class/tree.php ' );
489490 foreach ($ category_arr as $ cat ) {
490491 try {
491492 $ cid = $ cat ->getVar ('category_id ' );
@@ -497,7 +498,6 @@ protected function loadMenus()
497498 $ crit ->setSort ('items_position, items_title ' );
498499 $ crit ->setOrder ('ASC ' );
499500 $ items_arr = $ menusitemsHandler ->getAll ($ crit );
500- include_once $ GLOBALS ['xoops ' ]->path ('class/tree.php ' );
501501 $ myTree = new XoopsObjectTree ($ items_arr , 'items_id ' , 'items_pid ' );
502502 // recursive closure to build nested structure
503503 $ buildNested = function ($ treeObj , $ parentId = 0 ) use (&$ buildNested ) {
You can’t perform that action at this time.
0 commit comments