'Slugify the username and replace - with _ to meet username requirements'

@classmethod
def _make_username(cls, username):

    from django.template.defaultfilters import slugify
    from unidecode import unidecode
    slugified_name = slugify(unidecode(username)).replace('-', '_')
    slugified_name = slugified_name[:30]
    if (len(username) < 4):
        slugified_name = None
    return slugified_name
