if (!ImapFolder.isFolderVisible(folder)) {
if (!ImapFolder.isFolderVisible(folder, mSession)) {
    boolean doSTATUS(String tag, String folderName, int status) throws IOException {        if (!checkState(tag, ImapSession.STATE_AUTHENTICATED))            return CONTINUE_PROCESSING;        folderName = ImapFolder.importPath(folderName, mSession);        StringBuffer data = new StringBuffer();        try {            GetFolderOperation op = new GetFolderOperation(mSession, getContext(), mMailbox, Requester.IMAP, folderName);            op.schedule();            Folder folder = op.getFolder();        	            if (!ImapFolder.isFolderVisible(folder)) {                ZimbraLog.imap.info("STATUS failed: folder not visible: " + folderName);                sendNO(tag, "STATUS failed");                return CONTINUE_PROCESSING;            }            // note: we're not supporting UIDNEXT; see the comments in selectFolder()            if ((status & STATUS_MESSAGES) != 0)                data.append(data.length() > 0 ? " " : "").append("MESSAGES ").append(folder.getMessageCount());            // FIXME: hardcoded "RECENT 0"            if ((status & STATUS_RECENT) != 0)                data.append(data.length() > 0 ? " " : "").append("RECENT ").append(0);            if ((status & STATUS_UIDVALIDITY) != 0)                data.append(data.length() > 0 ? " " : "").append("UIDVALIDITY ").append(ImapFolder.getUIDValidity(folder));            if ((status & STATUS_UNSEEN) != 0)                data.append(data.length() > 0 ? " " : "").append("UNSEEN ").append(folder.getUnreadCount());        } catch (ServiceException e) {            if (e.getCode() == MailServiceException.NO_SUCH_FOLDER)                ZimbraLog.imap.info("STATUS failed: no such folder: " + folderName);            else                ZimbraLog.imap.warn("STATUS failed", e);            sendNO(tag, "STATUS failed");            return canContinue(e);        }        sendUntagged("STATUS " + ImapFolder.formatPath(folderName, mSession) + " (" + data + ')');        sendNotifications(true, false);        sendOK(tag, "STATUS completed");        return CONTINUE_PROCESSING;    }