Fix potential error when multiple image downloads in a row fail