jnordberg / gif.js

JavaScript GIF encoding library
http://jnordberg.github.io/gif.js/
MIT License
4.74k stars 667 forks source link

Simple validation for render method #137

Open eagleloid opened 3 years ago

eagleloid commented 3 years ago

Just added a validation check for the render method in case user attempt to render without any frames. Allows the user to call it again without having to reconstruct the class.

Also set the @running variable to false after 'finished' is emitted in the finishRendering method for similar reason as above.