public void setSubStatus(SubType subStatus) {
        // Optimization: Load user only if we need to set the nickname of the roster item
        if ("".equals(nickname) && (subStatus == SUB_BOTH || subStatus == SUB_TO)) {
            try {
                nickname = UserNameManager.getUserName(jid);
            }
            catch (UserNotFoundException e) {
                // Do nothing
            }
        }
        this.subStatus = subStatus;
    }
<p>Set the current subscription status of the item.</p>

@param subStatus The subscription status of the item
xmppserver/src/main/java/org/jivesoftware/openfire/roster/RosterItem.java