Adds the boilerplate for a custom ui-router state change error handler.