Skip to content

Commit

Permalink
Merge pull request #35 from limosa-io/feature/allow-not-registering-r…
Browse files Browse the repository at this point in the history
…outes

allow not registering routes
  • Loading branch information
arietimmerman committed Mar 22, 2024
2 parents 4fe4bf2 + e52905e commit b248625
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/PassportServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -179,11 +179,13 @@ protected function registerRoutes()
{
parent::registerRoutes();

Route::group([
'namespace' => 'Laravel\Passport\Http\Controllers',
], function () {
$this->loadRoutesFrom(__DIR__ . '/../src/routes/web.php');
});
if (Passport::$registersRoutes) {
Route::group([
'namespace' => 'Laravel\Passport\Http\Controllers',
], function () {
$this->loadRoutesFrom(__DIR__ . '/../src/routes/web.php');
});
}
}

public function register()
Expand Down

0 comments on commit b248625

Please sign in to comment.