Last active
September 4, 2016 04:55
-
-
Save overtrue/ff6cd3a4e869fbaf6c01 to your computer and use it in GitHub Desktop.
PHP Tips
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Http; | |
use Illuminate\Foundation\Http\Kernel as HttpKernel; | |
class Kernel extends HttpKernel { | |
/** | |
* The application's global HTTP middleware stack. | |
* | |
* @var array | |
*/ | |
protected $middleware = [ | |
'Illuminate\Foundation\Http\Middleware\CheckForMaintenanceMode', | |
'Illuminate\Cookie\Middleware\EncryptCookies', | |
'Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse', | |
'Illuminate\Session\Middleware\StartSession', | |
'Illuminate\View\Middleware\ShareErrorsFromSession', | |
]; | |
/** | |
* The application's route middleware. | |
* | |
* @var array | |
*/ | |
protected $routeMiddleware = [ | |
'auth' => 'App\Http\Middleware\Authenticate', | |
'auth.basic' => 'Illuminate\Auth\Middleware\AuthenticateWithBasicAuth', | |
'guest' => 'App\Http\Middleware\RedirectIfAuthenticated', | |
'csrf' => 'App\Http\Middleware\VerifyCsrfToken', | |
]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
5.1以后可以直接在VerifyCsrfToken中添加except route