diff --git a/library/Icinga/Web/Navigation/NavigationItem.php b/library/Icinga/Web/Navigation/NavigationItem.php index 4a99fa295..c56dab7e4 100644 --- a/library/Icinga/Web/Navigation/NavigationItem.php +++ b/library/Icinga/Web/Navigation/NavigationItem.php @@ -596,11 +596,15 @@ class NavigationItem implements IteratorAggregate */ public function conflictsWith(NavigationItem $item) { + if (! $item instanceof $this) { + return false; + } + if ($this->getUrl() === null || $item->getUrl() === null) { return false; } - return $this->getUrl() !== $item->getUrl(); + return !$this->getUrl()->matches($item->getUrl()); } /**