From 95c013f21bf6fb62400e8c501608250c60964d79 Mon Sep 17 00:00:00 2001 From: Mohammad Alavi Date: Fri, 15 Apr 2022 12:08:05 +0430 Subject: [PATCH] feat: enable `can` Laravel middleware --- app/Ship/Kernels/HttpKernel.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/app/Ship/Kernels/HttpKernel.php b/app/Ship/Kernels/HttpKernel.php index ec128f4e1..01e88ca59 100644 --- a/app/Ship/Kernels/HttpKernel.php +++ b/app/Ship/Kernels/HttpKernel.php @@ -83,8 +83,7 @@ class HttpKernel extends LaravelHttpKernel 'auth' => Authenticate::class, // 'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class, 'cache.headers' => SetCacheHeaders::class, - // Note: This middleware is disabled because Authorization functionality is provided by the Authorization container. - // 'can' => \Illuminate\Auth\Middleware\Authorize::class, + 'can' => Authorize::class, // Note: The "guest" middleware is registered by MiddlewareServiceProvider in Authentication Container // 'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class, 'password.confirm' => RequirePassword::class,