Fix Request Animation Frame

Fix this code view the diff