def METHOD_NAME(doc, n_conditions):
    """
    Check that csub document was updated correctly at DB.
    :param doc: the doc to check
    :param n_conditions: the expected number of conditions in the document
    :return: True if the check is ok, False otherwise
    """
    if (not CONDITIONS in doc):
        print "debug1"
        return False
    ck_conditions = len(doc[CONDITIONS])
    if (n_conditions != ck_conditions):
        print "debug 2: %d %d" % (n_conditions, ck_conditions)
        return False
    return True