<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def join_tags(tags):
 """ Given list of ``Tag`` instances, creates a string representation of the list suitable for editing by the user, such that submitting the given string representation back without changing it will give the same list of tags. Tag names which contain DELIMITER will be double quoted. Adapted from Taggit's _edit_string_for_tags() Ported from Jonathan Buchanan's `django-tagging <http://django-tagging.googlecode.com/>`_ """

    names = []
    delimiter = settings.TAGGIT_SELECTIZE['DELIMITER']
    for tag in tags:
        name = tag.name
        if delimiter in name or ' ' in name:
            names.append('"%s"' % name)
        else:
            names.append(name)
    return delimiter.join(sorted(names))