def convert_str_tags_to_list(i):
    """
    Input:  either a list, or a string of comma-separated tags.

    Output: If i is a list, it's returned.
            If i is a string, the list of tags it represents is returned 
            (each tag is stripped of leading and trailing whitespace).

    """
    r = []
    if type(i) == list:
        r = i
    else:
        ii = i.split(',')
        for q in ii:
            q = q.strip()
            if q != '':
                r.append(q)
    return r
