Skip to content

Commit

Permalink
Stop throwing errors for breadcrumbs
Browse files Browse the repository at this point in the history
  • Loading branch information
HugoJF committed Sep 25, 2020
1 parent f34dc47 commit 16c2a53
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
4 changes: 2 additions & 2 deletions config/breadcrumbs.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@
*/

// When route-bound breadcrumbs are used but the current route doesn't have a name (UnnamedRouteException)
'unnamed-route-exception' => true,
'unnamed-route-exception' => false,

// When route-bound breadcrumbs are used and the matching breadcrumb doesn't exist (InvalidBreadcrumbException)
'missing-route-bound-breadcrumb-exception' => true,
'missing-route-bound-breadcrumb-exception' => false,

// When a named breadcrumb is used but doesn't exist (InvalidBreadcrumbException)
'invalid-named-breadcrumb-exception' => true,
Expand Down
5 changes: 5 additions & 0 deletions routes/breadcrumbs.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@
$trail->push('Register', route('register'));
});

// Register
Breadcrumbs::for('password.request', function ($trail) {
$trail->push('Password reset', route('register'));
});

// Password set
Breadcrumbs::for('accounts.setup', function ($trail, $user) {
$trail->push('Register', route('accounts.setup', $user));
Expand Down

0 comments on commit 16c2a53

Please sign in to comment.