Skip to content
This repository has been archived by the owner on Feb 4, 2021. It is now read-only.

Commit

Permalink
#215 - Do not create admin menu item if the component has no admin fu…
Browse files Browse the repository at this point in the history
…nctionality
  • Loading branch information
johanjanssens committed Jul 8, 2015
1 parent 1219995 commit faca7f2
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/libraries/cms/installer/adapter/component.php
Original file line number Diff line number Diff line change
Expand Up @@ -1263,7 +1263,12 @@ protected function _buildAdminMenus()
// Ok, now its time to handle the menus. Start with the component root menu, then handle submenus.
$menuElement = $this->manifest->administration->menu;

if ($menuElement)
// @TODO: Just do not create the menu if $menuElement not exist
if (in_array((string) $menuElement['hidden'], array('true', 'hidden')))
{
return true;
}
elseif ($menuElement)
{
$data = array();
$data['menutype'] = 'main';
Expand Down

0 comments on commit faca7f2

Please sign in to comment.