Clean up user state and login state