login into account automatically by detecting when the user is logged out.