Skip to content

Commit

Permalink
Reorder methods in class
Browse files Browse the repository at this point in the history
  • Loading branch information
caendesilva committed Mar 24, 2024
1 parent d3b2044 commit 1ed674b
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -82,14 +82,6 @@ public function __toString(): string
return $this->getLink();
}

/**
* If the navigation item is a link to a routed page, get the corresponding page instance.
*/
public function getPage(): ?HydePage
{
return $this->destination instanceof Route ? $this->destination->getPage() : null;
}

/**
* Resolve the destination link of the navigation item.
*/
Expand Down Expand Up @@ -127,6 +119,14 @@ public function getGroupKey(): ?string
return $this->group;
}

/**
* If the navigation item is a link to a routed page, get the corresponding page instance.
*/
public function getPage(): ?HydePage
{
return $this->destination instanceof Route ? $this->destination->getPage() : null;
}

/**
* Check if the NavigationItem instance is the current page being rendered.
*/
Expand Down

0 comments on commit 1ed674b

Please sign in to comment.