mirror of
https://github.com/andatoshiki/toshiki-home-nuxt3.git
synced 2026-06-06 01:06:27 +00:00
fix(allowed origin): add pre-assigned nelify address url to allowed origin list for test deployment rundown
This commit is contained in:
parent
d840674d2a
commit
a7a1c884b2
@ -23,6 +23,13 @@ const handler: Handler = async () => {
|
||||
|
||||
// Origin for CORS
|
||||
const origin = process.env.NODE_ENV === 'production' ? 'https://toshiki.dev' : 'http://localhost:3000'
|
||||
const allowedOrigins = ['https://toshiki.dev', 'http://localhost:3000', 'https://toshiki-home-nuxt3.netlify.app/']
|
||||
if (!allowedOrigins.includes(origin)) {
|
||||
return {
|
||||
statusCode: 403,
|
||||
body: 'Forbidden'
|
||||
}
|
||||
}
|
||||
|
||||
// Map track function
|
||||
const mapTrack = (track: any): any => {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user