CORS authorization
This commit is contained in:
@ -14,7 +14,7 @@ class CORS
|
|||||||
if ($request->getMethod() === 'OPTIONS') {
|
if ($request->getMethod() === 'OPTIONS') {
|
||||||
return $this->responseFactory->createResponse()
|
return $this->responseFactory->createResponse()
|
||||||
->withHeader('Access-Control-Allow-Origin', '*')
|
->withHeader('Access-Control-Allow-Origin', '*')
|
||||||
->withHeader('Access-Control-Allow-Methods', 'POST,GET,OPTIONS');
|
->withHeader('Access-Control-Allow-Methods', 'POST,GET,OPTIONS,AUTHORIZATION');
|
||||||
}
|
}
|
||||||
return $handler->handle($request);
|
return $handler->handle($request);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user