class Illuminate / Http / Middleware / HandleCors

HandleCors

Properties

protected

$container Container

The container instance.

Default: null
protected

$cors Fruitcake\...\CorsService

The CORS service instance.

Default: null

Methods

public

__construct ( Container $container , Fruitcake\...\CorsService $cors ) : void

Create a new middleware instance.

Parameters

  • $container Container
  • $cors Fruitcake\...\CorsService
public

handle ( $request , Closure $next ) : Response

Handle the incoming request.

Parameters

protected

hasMatchingPath ( Request $request ) : bool

Get the path from the configuration to determine if the CORS service should run.

Parameters

protected

getPathsByHost ( string $host ) : array

Get the CORS paths for the given host.

Parameters

  • $host string