Skip to content

Commit

Permalink
Load cached breadcrumbs on boot
Browse files Browse the repository at this point in the history
  • Loading branch information
inxilpro committed Sep 28, 2021
1 parent 071a155 commit 031f39b
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/Support/GretelServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ public function boot()
$this->bootViews();
$this->bootBladeComponents();
$this->bootCommands();
$this->bootCachedBreadcrumbs();
}

public function register()
Expand Down Expand Up @@ -111,4 +112,13 @@ protected function bootCommands(): self

return $this;
}

protected function bootCachedBreadcrumbs(): self
{
if ($this->app->routesAreCached()) {
$this->app->make(Cache::class)->load();
}

return $this;
}
}

0 comments on commit 031f39b

Please sign in to comment.