Fix subscribe and unsubscribe. Fixes #12