Forum

Create a custom middlewareGroup in custom package

This is not working:

    public function boot(\Illuminate\Routing\Router $router)
    {
        $router->middlewareGroup('backend', array(
                \App\Http\Middleware\EncryptCookies::class,
                \Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
                \Illuminate\Session\Middleware\StartSession::class,
                \Krucas\Notification\Middleware\NotificationMiddleware::class,
                \Illuminate\View\Middleware\ShareErrorsFromSession::class,
                \App\Http\Middleware\VerifyCsrfToken::class
            )
        );

I see its part of the array, but i think you need to reload something.

isomis
isomis
  • 1 week ago

You arent getting answers cause your question is too vague.