how u doing?
Here is my code:
const router = Router();
router.use(
`${routePrefix}/v1/associate-auth/`,
associateAuthRoutesV1(router)
);
router.use(
`${routePrefix}/v1/associate/`,
JWTVerify,
associateRoutesV1(router)
);
app.use('/', router);
Here is an exemple of my routes content:
router.post('/', async (_req, res) => {
res.send('OK');
});
The problem is: When I don't set the root('/') in one of routes file, Express find the next file with the same method in root ('/').
How can I configure to return 404 when there is no route specify?