fixed animation glitch on first load