Skip to content

Commit

Permalink
CORS rollback
Browse files Browse the repository at this point in the history
  • Loading branch information
alllenshibu committed Jan 14, 2025
1 parent 0a54f6e commit 5d8e5ca
Show file tree
Hide file tree
Showing 2 changed files with 2,315 additions and 6,625 deletions.
9 changes: 8 additions & 1 deletion apps/core-admin/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,14 @@ const allowedOrigins = [
'https://admin.eventsync.iedcmec.in',
];

app.use(cors());
app.use(
cors({
origin: allowedOrigins,
methods: ['GET', 'POST', 'PUT', 'DELETE', 'OPTIONS'],
credentials: true, // Allow cookies or authorization headers
allowedHeaders: ['Content-Type', 'Authorization'],
}),
);

app.use(
bodyParser.json({
Expand Down
Loading

0 comments on commit 5d8e5ca

Please sign in to comment.