public function createPreflightCorsResponseWithRouteOptions(HttpRequest $request, $routeMatch = null)
    {
        $options = $this->options;
        if ($routeMatch instanceof RouteMatch || $routeMatch instanceof DeprecatedRouteMatch) {
            $options->setFromArray($routeMatch->getParam(CorsOptions::ROUTE_PARAM) ?: []);
        }
        $response = $this->createPreflightCorsResponse($request);

        return $response;
    }
public function createPreflightCorsResponseWithRouteOptions(HttpRequest $request, $routeMatch = null)
    {
        $options = $this->options;
        if ($routeMatch instanceof RouteMatch || $routeMatch instanceof DeprecatedRouteMatch) {
            $options->setFromArray($routeMatch->getParam(CorsOptions::ROUTE_PARAM) ?: []);
        }
        $response = $this->createPreflightCorsResponse($request);

        return $response;
    }
public function createPreflightCorsResponseWithRouteOptions ( HttpRequest $ request , $ routeMatch = null ) { $ options = $ this -> options ; if ( $ routeMatch instanceof RouteMatch || $ routeMatch instanceof DeprecatedRouteMatch ) { $ options -> setFromArray ( $ routeMatch -> getParam ( CorsOptions :: ROUTE_PARAM ) ? : [ ] ) ; } $ response = $ this -> createPreflightCorsResponse ( $ request ) ; return $ response ; }
Create a preflight response by adding the correspoding headers which are merged with per-route configuration

@param HttpRequest                          $request
@param RouteMatch|DeprecatedRouteMatch|null $routeMatch

@return HttpResponse
Create a preflight response by adding the correspoding headers which are merged with per - route configuration