Skip to content

Commit

Permalink
fix: update allowedHeaders MetascanServerApp
Browse files Browse the repository at this point in the history
  • Loading branch information
chloezxyy committed Nov 21, 2023
1 parent 4f4832d commit e9592dd
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions apps/server/src/MetascanServerApp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,13 @@ export class MetascanServerApp<App extends NestFastifyApplication = NestFastifyA

async configureApp(app): Promise<void> {
app.enableCors({
allowedHeaders: 'no-cors',
allowedHeaders: '*',
methods: ['GET', 'PUT', 'POST', 'DELETE'],
maxAge: 60 * 24 * 7,
origin:
process.env.NODE_ENV === 'production'
? [
'https://quantumbridge.app',
'https://admin.quantumbridge.app',
'https://meta.defiscan.live/',
/https:\/\/([^.]*.\.)*defimetascan\.app/, // allow all subdomains of quantumbridge
/https:\/\/([^.]*.)--defimetascan\.netlify\.app/, // allow all netlify preview deployments
/https?:\/\/localhost(:\d+)?/, // allow localhost connection
Expand Down

0 comments on commit e9592dd

Please sign in to comment.