use "forname lastname" as default username, with a space
This commit is contained in:
parent
96aca54f61
commit
85bddf6872
@ -31,7 +31,7 @@ def gen_username(first_name, last_name):
|
|||||||
"""
|
"""
|
||||||
generates the username for new users.
|
generates the username for new users.
|
||||||
"""
|
"""
|
||||||
testname = "%s%s" % (first_name, last_name)
|
testname = "%s %s" % (first_name.strip(), last_name.strip())
|
||||||
try:
|
try:
|
||||||
User.objects.get(username=testname)
|
User.objects.get(username=testname)
|
||||||
except User.DoesNotExist:
|
except User.DoesNotExist:
|
||||||
|
Loading…
Reference in New Issue
Block a user