Fixed the error handling in URL response processing.