Skip to content

Commit

Permalink
#49 usejson must be before routes
Browse files Browse the repository at this point in the history
  • Loading branch information
leoleader committed Oct 10, 2023
1 parent bed9af4 commit b64dafb
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions scylla-server/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ app.get('/', (_req: Request, res: Response) => {
});

app.use(cors());
app.use(express.json());

app.use('/nodes', nodeRouter);
app.use('/locations', locationRouter);
Expand All @@ -27,8 +28,6 @@ app.use('/runs', runRouter);
app.use('/data', dataRouter);
app.use('/datatypes', dataTypeRouter);

app.use(express.json());

const server = app.listen(port, () => {
console.log(`Server is running on port ${port}`);
});
Expand Down

0 comments on commit b64dafb

Please sign in to comment.