Update CORS to allow GitHub.dev origins

This commit is contained in:
Sara Jane (SJ)
2026-02-02 17:25:21 +00:00
committed by GitHub
parent 3284af267a
commit ee5b2b2bdc

View File

@ -35,11 +35,13 @@ function isAllowedOrigin(origin) {
try { try {
const host = new URL(origin).hostname const host = new URL(origin).hostname
if (host.endsWith('.vercel.app')) return true return (
host.endsWith('.vercel.app') ||
host.endsWith('.app.github.dev')
)
} catch { } catch {
// ignore return false
} }
return false
} }
const corsOptions = { const corsOptions = {