Added route error handling