Skip to content

Commit

Permalink
Merge pull request #2 from smtlk/master
Browse files Browse the repository at this point in the history
Prevent CLI errors when running Artisan commands
  • Loading branch information
Rukhsar committed Mar 3, 2018
2 parents 573c3f3 + 9ae5796 commit 3a6d6b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ActiveRouteServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public function register()

// Register Singletion
$this->app->singleton('active', function($app) {
return new Active($app['router']->current()->getName());
return new Active(optional($app['router']->current())->getName());
});
}

Expand Down

0 comments on commit 3a6d6b7

Please sign in to comment.