just use web group by default
This commit is contained in:
parent
1d5e88d0fb
commit
5c30c98db9
|
@ -11,10 +11,6 @@
|
||||||
|
|
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
Route::group(['middleware' => ['web']], function () {
|
Route::get('/', function () {
|
||||||
|
|
||||||
Route::get('/', function () {
|
|
||||||
return view('welcome');
|
return view('welcome');
|
||||||
});
|
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
class RouteServiceProvider extends ServiceProvider
|
class RouteServiceProvider extends ServiceProvider
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* This namespace is applied to the controller routes in your routes file.
|
* This namespace is applied to your controller routes.
|
||||||
*
|
*
|
||||||
* In addition, it is set as the URL generator's root namespace.
|
* In addition, it is set as the URL generator's root namespace.
|
||||||
*
|
*
|
||||||
|
@ -37,7 +37,22 @@ public function boot(Router $router)
|
||||||
*/
|
*/
|
||||||
public function map(Router $router)
|
public function map(Router $router)
|
||||||
{
|
{
|
||||||
$router->group(['namespace' => $this->namespace], function ($router) {
|
$this->mapWebRoutes($router);
|
||||||
|
|
||||||
|
//
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Define the "web" routes for the application.
|
||||||
|
*
|
||||||
|
* @param \Illuminate\Routing\Router $router
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
|
protected function mapWebRoutes(Router $router)
|
||||||
|
{
|
||||||
|
$router->group([
|
||||||
|
'namespace' => $this->namespace, 'middleware' => 'web'
|
||||||
|
], function ($router) {
|
||||||
require app_path('Http/routes.php');
|
require app_path('Http/routes.php');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue