Small code optimization
authorMarcel Werk <burntime@woltlab.com>
Fri, 24 Jun 2016 13:41:06 +0000 (15:41 +0200)
committerMarcel Werk <burntime@woltlab.com>
Fri, 24 Jun 2016 13:41:12 +0000 (15:41 +0200)
com.woltlab.wcf/templates/pageHeaderMenu.tpl
com.woltlab.wcf/templates/pageMenuMobile.tpl

index 70d461e64a7dc1de059ac626d51fe6389a032754..bb79215d9688f97f575452adc34e6fd6fcdc1ef8 100644 (file)
@@ -1 +1 @@
-{@$__wcf->getBoxHandler()->getBoxes('mainMenu')[0]->render()}
+{@$__wcf->getBoxHandler()->getBoxByIdentifier('com.woltlab.wcf.MainMenu')->render()}
index 9af591928e7ef64dd616b4553d9c1452380a070d..204fcdb1f40292c63b0a959599020c24f64a18bb 100644 (file)
@@ -8,7 +8,7 @@
                                <span class="menuOverlayItemTitle"></span>
                        </a>
                        <ol class="menuOverlayItemList">*}
-                               {foreach from=$__wcf->getBoxHandler()->getBoxes('mainMenu')[0]->getMenu()->getMenuItemNodeList() item=menuItemNode}
+                               {foreach from=$__wcf->getBoxHandler()->getBoxByIdentifier('com.woltlab.wcf.MainMenu')->getMenu()->getMenuItemNodeList() item=menuItemNode}
                                        <li class="menuOverlayItem">
                                                {assign var=__outstandingItems value=$menuItemNode->getOutstandingItems()}
                                                <a href="{$menuItemNode->getURL()}" class="menuOverlayItemLink{if $__outstandingItems} menuOverlayItemBadge{/if}{if $menuItemNode->isActiveNode()} active{/if}">