From e99aaea193a500aed94b2c0429fa828f85e3d355 Mon Sep 17 00:00:00 2001 From: CallMeVerity Date: Wed, 3 Jun 2026 04:24:09 +0100 Subject: [PATCH] Expose Content-Range, Accept-Ranges, Content-Length in CORS --- backend/src/index.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/backend/src/index.ts b/backend/src/index.ts index 08d6aca..1bf75e1 100644 --- a/backend/src/index.ts +++ b/backend/src/index.ts @@ -11,7 +11,11 @@ const PORT = parseInt(process.env.PORT || "3001"); const STATIC_DIR = process.env.STATIC_DIR || "./public"; const app = new Elysia() - .use(cors()) + .use( + cors({ + exposeHeaders: ["Content-Range", "Accept-Ranges", "Content-Length"], + }), + ) .onError(({ error }) => { console.error("Unhandled error:", error); return status(500, { error: "Internal server error" });