Skip to content

Commit

Permalink
order middleware in bootstrap file
Browse files Browse the repository at this point in the history
  • Loading branch information
CarlosQ96 committed Sep 8, 2024
1 parent 78e1911 commit 84f7cca
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/server/bootstrap.ts
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,9 @@ export async function bootstrap() {
},
}),
);
// AdminJs!
app.use(adminJsRootPath, await getAdminJsRouter());
app.use(bodyParserJson);
app.use('/apigive', apiGivRouter);
app.use(SOCIAL_PROFILES_PREFIX, oauth2CallbacksRouter);
app.post(
Expand Down Expand Up @@ -310,10 +313,6 @@ export async function bootstrap() {
reject(err); // Reject the Promise if there's an error starting the server
});
});

// AdminJs!
app.use(adminJsRootPath, await getAdminJsRouter());
app.use(bodyParserJson);
} catch (err) {
logger.fatal('bootstrap() error', err);
}
Expand Down

0 comments on commit 84f7cca

Please sign in to comment.