X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=auth%2Fmanifoldbackend.py;h=afb87821930813087c98d5793e21ea3cef8b1018;hb=2c1bd9325dc325f82d99807fcdb9d14ae148f167;hp=eb87ab8796ae0fc869607ca9a0f48299b8347e54;hpb=da0b290c0d86afe3d388f4b1a8be60a70b39ed92;p=unfold.git diff --git a/auth/manifoldbackend.py b/auth/manifoldbackend.py index eb87ab87..afb87821 100644 --- a/auth/manifoldbackend.py +++ b/auth/manifoldbackend.py @@ -61,9 +61,13 @@ class ManifoldBackend: except User.DoesNotExist: # Create a user in Django's local database user = User.objects.create_user(username, username, 'passworddoesntmatter') - user.first_name = "DUMMY_FIRST_NAME" #person['first_name'] - user.last_name = "DUMMY LAST NAME" # person['last_name'] user.email = person['email'] + + if 'firstname' in person: + user.first_name = person['firstname'] + if 'lastname' in person: + user.last_name = person['lastname'] + return user # Required for your backend to work properly - unchanged in most scenarios