c
Showing
1 changed file
with
3 additions
and
2 deletions
| ... | @@ -23,9 +23,10 @@ class Cors | ... | @@ -23,9 +23,10 @@ class Cors |
| 23 | 'Access-Control-Allow-Headers'=> 'Content-Type, X-Auth-Token, Origin', | 23 | 'Access-Control-Allow-Headers'=> 'Content-Type, X-Auth-Token, Origin', |
| 24 | 'Access-Control-Max-Age'=> '28800' | 24 | 'Access-Control-Max-Age'=> '28800' |
| 25 | ]; | 25 | ]; |
| 26 | 26 | if($request->getMethod() == "OPTIONS") { | |
| 27 | // The client-side application can set only headers allowed in Access-Control-Allow-Headers | ||
| 27 | return Response::make('OK', 200, $headers); | 28 | return Response::make('OK', 200, $headers); |
| 28 | 29 | } | |
| 29 | 30 | ||
| 30 | $response = $next($request); | 31 | $response = $next($request); |
| 31 | foreach($headers as $key => $value) | 32 | foreach($headers as $key => $value) | ... | ... |
-
Please register or sign in to post a comment