修复跨域报错

This commit is contained in:
2026-03-30 12:13:20 +08:00
parent 09ef8edd15
commit 8669a20dc8
2 changed files with 2 additions and 2 deletions

View File

@@ -30,7 +30,7 @@ class AllowCrossDomain implements MiddlewareInterface
'Access-Control-Allow-Credentials' => 'true',
'Access-Control-Max-Age' => '1800',
'Access-Control-Allow-Methods' => 'GET, POST, PUT, DELETE, PATCH, OPTIONS',
'Access-Control-Allow-Headers' => 'Content-Type, Authorization, batoken, ba-user-token, think-lang, lang',
'Access-Control-Allow-Headers' => 'Content-Type, Authorization, batoken, ba-user-token, think-lang, lang, server',
];
$origin = $request->header('origin');
if (is_array($origin)) {