perf: Third-party user login failed

pull/14126/head
feng 2024-09-12 10:19:40 +08:00
parent ab529fd22c
commit b00f3a851c
1 changed files with 2 additions and 0 deletions

View File

@ -52,6 +52,8 @@ def user_authenticated_handle(user, created, source, attrs=None, **kwargs):
if created:
user.source = source
user.save()
if created and isinstance(attrs, dict):
org_ids = bind_user_to_org_role(user)
group_names = attrs.get('groups')
bind_user_to_group(org_ids, group_names, user)