At the moment, when a method returns an error, each route needs to handle this behaviour. It would be better if each route accepts the next callback as a third argument and call that with the error if one occurs. Error handling can then be handled in a single place.
At the moment, when a method returns an error, each route needs to handle this behaviour. It would be better if each route accepts the
next
callback as a third argument and call that with the error if one occurs. Error handling can then be handled in a single place.