Fixes #104, allows a user to logout of their account, includes tests