This commit is contained in:
Rachid Mrad 2023-12-13 15:41:18 -05:00
parent 4adeb6722b
commit 9c8ed1682b
No known key found for this signature in database
GPG key ID: EF38E4CEC4A8F3CF
4 changed files with 10 additions and 10 deletions

View file

@ -67,7 +67,7 @@ class OpenIdConnectBackend(ModelBackend):
def update_existing_user(self, user, kwargs):
"""Update other fields without overwriting first_name and last_name.
Overwrite first_name and last_name if not empty string"""
for key, value in kwargs.items():
# Check if the key is not first_name or last_name or value is not empty string
if key not in ["first_name", "last_name"] or value: