Don't spam the log with "Undefined index showInHeader"
Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
parent
d9ebc2626f
commit
81d87b01fe
1 changed files with 3 additions and 5 deletions
|
@ -472,6 +472,7 @@ class OC_App {
|
|||
$activeAppIndex = -1;
|
||||
$activeApp = OC::$server->getNavigationManager()->getActiveEntry();
|
||||
foreach ($list as $index => &$navEntry) {
|
||||
$navEntry['showInHeader'] = true;
|
||||
if ($navEntry['id'] == $activeApp) {
|
||||
$navEntry['active'] = true;
|
||||
$activeAppIndex = $index;
|
||||
|
@ -494,14 +495,11 @@ class OC_App {
|
|||
}
|
||||
|
||||
foreach ($list as $index => &$navEntry) {
|
||||
$navEntry['showInHeader'] = false;
|
||||
if($index < $headerIconCount) {
|
||||
$navEntry['showInHeader'] = true;
|
||||
if($index >= $headerIconCount) {
|
||||
$navEntry['showInHeader'] = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
return $list;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue