Fixed the .remove() call that only works in Chrome

Fixes #61, thanks @jusbuc2k