Browse Source

Rename CSRF middleware.

Taylor Otwell 10 years ago
parent
commit
ec9edec9a2

+ 1 - 1
app/Http/Kernel.php

@@ -17,7 +17,7 @@ class Kernel extends HttpKernel {
 		'Illuminate\Session\Middleware\ReadSession',
 		'Illuminate\Session\Middleware\WriteSession',
 		'Illuminate\View\Middleware\ShareErrorsFromSession',
-		'App\Http\Middleware\ValidateCsrfToken',
+		'App\Http\Middleware\CsrfTokenIsValid',
 	];
 
 	/**

+ 1 - 1
app/Http/Middleware/ValidateCsrfToken.php → app/Http/Middleware/CsrfTokenIsValid.php

@@ -4,7 +4,7 @@ use Closure;
 use Illuminate\Contracts\Routing\Middleware;
 use Illuminate\Session\TokenMismatchException;
 
-class ValidateCsrfToken implements Middleware {
+class CsrfTokenIsValid implements Middleware {
 
 	/**
 	 * Handle an incoming request.

+ 1 - 1
app/Providers/RouteServiceProvider.php

@@ -24,7 +24,7 @@ class RouteServiceProvider extends ServiceProvider {
 	protected $middleware = [
 		'auth' => 'App\Http\Middleware\Authenticated',
 		'auth.basic' => 'App\Http\Middleware\AuthenticatedWithBasicAuth',
-		'csrf' => 'App\Http\Middleware\VerifyCsrfToken',
+		'csrf' => 'App\Http\Middleware\CsrfTokenIsValid',
 		'guest' => 'App\Http\Middleware\IsGuest',
 	];