added islogged in logic to server