Skip to content

Commit

Permalink
Update CorsListener.php
Browse files Browse the repository at this point in the history
  • Loading branch information
pedelgado authored May 6, 2024
1 parent e761e1e commit a286185
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions app/EventListener/CorsListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,6 @@ public function __construct(KernelInterface $kernel)

public function onKernelResponse(ResponseEvent $event)
{
if ($this->kernel->getEnvironment() !== 'dev') {
return;
}

$response = $event->getResponse();
$response->headers->set('Access-Control-Allow-Origin', '*');
$response->headers->set('Access-Control-Allow-Methods', 'GET, POST, PUT, DELETE, OPTIONS');
Expand Down

0 comments on commit a286185

Please sign in to comment.