Minor change to error handling in request method.