Skip to content
This repository has been archived by the owner on Feb 16, 2023. It is now read-only.

Commit

Permalink
Remove headers from actual request
Browse files Browse the repository at this point in the history
  • Loading branch information
barryvdh authored Feb 15, 2017
1 parent 2ae501a commit 9bf14c1
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/Stack/CorsService.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,13 +88,6 @@ public function addActualRequestHeaders(Response $response, Request $request)
if ($this->options['exposedHeaders']) {
$response->headers->set('Access-Control-Expose-Headers', implode(', ', $this->options['exposedHeaders']));
}

if ($this->options['allowedHeaders']) {
$allowHeaders = $this->options['allowedHeaders'] === true
? strtoupper($request->headers->get('Access-Control-Request-Headers'))
: implode(', ', $this->options['allowedHeaders']);
$response->headers->set('Access-Control-Allow-Headers', $allowedHeaders);
}

return $response;
}
Expand Down

0 comments on commit 9bf14c1

Please sign in to comment.