Skip to content

Commit

Permalink
Merge pull request #177 from dachcom-digital/feature/alternate-route-…
Browse files Browse the repository at this point in the history
…event-routeitem

alternate route event: getter for current route item
  • Loading branch information
benwalch authored Jan 21, 2025
2 parents af0216a + 967cd6d commit a90db51
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions UPGRADE.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Upgrade Notes

## 5.1.1
- [IMPROVEMENT] alternate route event: getter for current route item
## 5.1.0
- [FEATURE] pimcore backend: object preview button
- [IMPROVEMENT] prevent applying str_contains on null value
Expand Down
5 changes: 5 additions & 0 deletions src/Event/AlternateDynamicRouteEvent.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,11 @@ public function getType(): string
return $this->type;
}

public function getCurrentRouteItem(): RouteItemInterface
{
return $this->currentRouteItem;
}

public function isCurrentRouteHeadless(): bool
{
return $this->currentRouteItem->isHeadless() === true;
Expand Down

0 comments on commit a90db51

Please sign in to comment.