Skip to content

Commit

Permalink
Remove routes from AddBreadMenuItem Listener (thedevdojo#4189)
Browse files Browse the repository at this point in the history
* Fix issue thedevdojo#3623

The line I'm removing is the cause of thedevdojo#3623. Once removed the BREAD creation seems to work as expected, however with it included it just causes exceptions to be thrown.

* Remove whitespace to make StyleCI happy
  • Loading branch information
mallardduck authored and emptynick committed Jul 20, 2019
1 parent 887b613 commit 03ef1b9
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions src/Listeners/AddBreadMenuItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@ public function __construct()
public function handle(BreadAdded $bread)
{
if (config('voyager.bread.add_menu_item') && file_exists(base_path('routes/web.php'))) {
require base_path('routes/web.php');

$menu = Voyager::model('Menu')->where('name', config('voyager.bread.default_menu'))->firstOrFail();

$menuItem = Voyager::model('MenuItem')->firstOrNew([
Expand Down

0 comments on commit 03ef1b9

Please sign in to comment.