Handle errors while downloading data