Fix for #5.
Thanks to cosmith