chore: replaced hardcoded values with env variables in app.module.ts, main.ts and utils.ts
This commit is contained in:
@@ -19,8 +19,10 @@ async function bootstrap() {
|
||||
|
||||
if (process.env.PRODUCTION === 'false') {
|
||||
console.log('Enabling CORS with development settings');
|
||||
|
||||
app.enableCors({
|
||||
origin: true,
|
||||
origin: process.env.WHITELISTED_ORIGINS.split(','),
|
||||
credentials: true,
|
||||
});
|
||||
} else {
|
||||
console.log('Enabling CORS with production settings');
|
||||
|
||||
Reference in New Issue
Block a user