}
    public synchronized User loginUser(String name, String password) {        User tmpUser = this.getFromUserListByName(name);        if (tmpUser == null) {            return null;        }        else {            if (tmpUser.getPassword().compareTo(password) == 0 && (!tmpUser.isLoggedIn())) {                tmpUser.setLoggedIn(true);                return tmpUser;            }            else { return null; }        }    }