team-genny / genny

0 stars 1 forks source link

Invalid paths under /api should return a JSON 404, instead of rewriting to /index.html #59

Closed fergcb closed 3 months ago

fergcb commented 3 months ago

Currently, providing an invalid path when trying to use API routes results in being rerouted to the front-end. Instead, there should be a catch-all hander for the /api route that returns a JSON error response in the same format as other API error messages, and a 404 status code.