Closed mgm1313 closed 2 weeks ago
Ah I just found out that's what the server.registerMiddleware(api.lib.createErrorMiddleware())
is for.. Might need some documentation :)
yup!
the error middleware makes http friendly errors from internal errors!
so use that :-)
Currently, if a user makes a request to an endpoint that is not defined (https://serverurl.com/non-existing-route), the server simply closes the connection. I think it would be more intuitive to give a 404.