Added isConnected() and isLogged() functions