Skip to content

Commit

Permalink
Fix submenu items not having their target attribute set.
Browse files Browse the repository at this point in the history
Signed-off-by: Micheal Mand <[email protected]>
  • Loading branch information
mikemand committed Dec 17, 2015
1 parent 6010e7c commit b51a614
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Providers/MenuServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ function () {
public function addItemToMenu(Menuitem $item, Builder $menu)
{
if ($this->hasChildren($item)) {
$this->addChildrenToMenu($item->title, $item->items, $menu, ['icon' => $item->icon]);
$this->addChildrenToMenu($item->title, $item->items, $menu, ['icon' => $item->icon, 'target' => $item->target]);
} else {
$target = $item->uri ?: $item->url;
$menu->url(
Expand Down Expand Up @@ -128,7 +128,7 @@ private function addSubItemToMenu(Menuitem $child, PingpongMenuItem $sub)
$this->addChildrenToMenu($child->title, $child->items, $sub);
} else {
$target = $child->uri ?: $child->url;
$sub->url($target, $child->title, 0, ['icon' => $child->icon]);
$sub->url($target, $child->title, 0, ['icon' => $child->icon, 'target' => $child->target]);
}
}

Expand Down

0 comments on commit b51a614

Please sign in to comment.