add the logout functionality