configured cors for local development

This commit is contained in:
2024-07-14 10:50:02 +00:00
parent 18c711686c
commit 5afc3c916b
3 changed files with 22 additions and 9 deletions

View File

@@ -1,5 +1,7 @@
<?php
$allowed_origins = env('IS_DEVELOPMENT_ENV') ? ['*'] : ['https://rms.rmto.ir'];
return [
/*
@@ -32,7 +34,8 @@ return [
/*
* Matches the request origin. `[*]` allows all origins.
*/
'allowed_origins' => ['*'],
// 'allowed_origins' => ['*'],
'allowed_origins' => $allowed_origins,
/*
* Matches the request origin with, similar to `Request::is()`