Fix how states of downloaded images is determined.