Added the ability to log out after doing the check