Fixed bug in XEM code for Failed Downloads