Skip to content

Commit

Permalink
updated header options
Browse files Browse the repository at this point in the history
  • Loading branch information
jazicorn committed Oct 5, 2023
1 parent ff6dfa9 commit 383b1d4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion apps/api/src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,16 @@ import cors from 'cors';
import * as dotenv from 'dotenv';
dotenv.config();


const corsOpt = process.env.CORS_URLS;

class App {
public app: Application;
public port: number;
private corsOptions;

constructor(authControllers, controllers) {
this.corsOptions = process.env.CORS_URLS;
this.corsOptions = corsOpt.split(',');
this.app = express();
this.port = parseInt(process.env.PORT as string) || 8000;
this.initMiddlewares();
Expand Down

0 comments on commit 383b1d4

Please sign in to comment.