I'm experiencing an odd issue where, if I write one route, it redirects to my home page, for reasons beyond me. But if I change even one letter in the route, it all works perfect.
It seems if I write exactly this, with 'entries' in the end, when going to that link, I just get redirected, no matter what the contents of the route. The following does not work (results in immediate redirect, seemingly never accesses the route at all):
router.get('/:username/curatas/:curataId/entries', function(req, res) {
// some code that works.
})
However, when I use absolutely any other choice of letters, it works! Such as omitting the 's' from 'entries' or adding and 'x', etc.
router.get('/:username/curatas/:curataId/entrie', function(req, res) {
// some code that works.
})
What could be the reason for this strange behavior? There's no error I've detected either.