blockstack_zones/parse_zone_file.py
def add_default_name(text):
    """
    Go through each line of the text and ensure that 
    a name is defined.  Use '@' if there is none.
    """
    global SUPPORTED_RECORDS

    lines = text.split("\n")
    ret = []
    for line in lines:
        tokens = tokenize_line(line)
        if len(tokens) == 0:
            continue

        if tokens[0] in SUPPORTED_RECORDS and not tokens[0].startswith("$"):
            # add back the name
            tokens = ['@'] + tokens 

        ret.append(serialize(tokens))

    return "\n".join(ret)
def add_default_name(text):
    """
    Go through each line of the text and ensure that 
    a name is defined.  Use '@' if there is none.
    """
    global SUPPORTED_RECORDS

    lines = text.split("\n")
    ret = []
    for line in lines:
        tokens = tokenize_line(line)
        if len(tokens) == 0:
            continue

        if tokens[0] in SUPPORTED_RECORDS and not tokens[0].startswith("$"):
            # add back the name
            tokens = ['@'] + tokens 

        ret.append(serialize(tokens))

    return "\n".join(ret)
def add_default_name ( text ) : global SUPPORTED_RECORDS lines = text . split ( "\n" ) ret = [ ] for line in lines : tokens = tokenize_line ( line ) if len ( tokens ) == 0 : continue if tokens [ 0 ] in SUPPORTED_RECORDS and not tokens [ 0 ] . startswith ( "$" ) : # add back the name tokens = [ '@' ] + tokens ret . append ( serialize ( tokens ) ) return "\n" . join ( ret )
Go through each line of the text and ensure that 
    a name is defined.  Use '@' if there is none.
Go through each line of the text and ensure that a name is defined . Use