diff --git a/components/EventManager.php b/components/EventManager.php index 79c63cd..c606abb 100644 --- a/components/EventManager.php +++ b/components/EventManager.php @@ -43,11 +43,12 @@ abstract class EventManager extends ComponentBase private function getBreadcrumbs(): Collection { $breadcrumbs = collect([]); + $breadcrumbs->push(['url' => '/', 'title' => 'Start', 'isActive' => false]); $breadcrumbs->push(['url' => $this->settings['indexUrl'], 'title' => 'Veranstaltungen', 'isActive' => $this->event === null]); if ($this->event) { $breadcrumbs->push([ - 'url' => (string) str($this->settings['singleUrl'])->replace(':slug', $this->event['slug']), + 'url' => str($this->settings['singleUrl'])->replace(':slug', $this->event['slug'])->toString(), 'title' => $this->event['name'], 'isActive' => !$this->isRegistering() ]); @@ -55,7 +56,7 @@ abstract class EventManager extends ComponentBase if ($this->event && $this->isRegistering()) { $breadcrumbs->push([ - 'url' => (string) str($this->settings['registerUrl'])->replace(':slug', $this->event['slug']), + 'url' => str($this->settings['registerUrl'])->replace(':slug', $this->event['slug'])->toString(), 'title' => 'Anmeldung', 'isActive' => true, ]);