From 9f9761cf48cd16b5937d047a7277008b7a7bee90 Mon Sep 17 00:00:00 2001 From: jszuminski Date: Wed, 30 Oct 2024 11:51:31 +0100 Subject: [PATCH] fix: set allowed origin methods to POST, GET, OPTIONS --- lib/server/server.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/server/server.js b/lib/server/server.js index 8523f469..286dda24 100644 --- a/lib/server/server.js +++ b/lib/server/server.js @@ -43,7 +43,11 @@ const app = express(); app.disable('x-powered-by'); // Enable CORS support -app.use(cors()); +app.use( + cors({ + methods: ['POST', 'GET', 'OPTIONS'] + }) +); // Enable parsing of form data (files) with Multer package const storage = multer.memoryStorage();