Here, you removed the condition that makes not animate images if the var is set to nil.