Fixes #36 -- Unregister was not working because it raised an error.