Fix animated GIF glitch