From b1992d69af455072f74b6d0b9d3e383d3a4519f9 Mon Sep 17 00:00:00 2001 From: yutent Date: Fri, 23 Feb 2024 20:54:26 +0800 Subject: [PATCH] Update middleware/cors.js --- middleware/cors.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/middleware/cors.js b/middleware/cors.js index 6b94c23..9e33204 100644 --- a/middleware/cors.js +++ b/middleware/cors.js @@ -32,7 +32,7 @@ export function createCors() { } res.set('Access-Control-Allow-Origin', `${protocol}//${host}`) - res.set('Access-Control-Allow-Methods', req.method) + res.set('Access-Control-Allow-Methods', '*') if (headers) { res.set('Access-Control-Allow-Headers', headers)