Skip to content

Commit

Permalink
add existing users to new group on event creation hotfix
Browse files Browse the repository at this point in the history
  • Loading branch information
alexrandaccio committed Mar 11, 2022
1 parent 34360b1 commit 6b1bca0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions backend/RxcVoiceApi/main/processviews.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,8 @@ def post(self, request, *args, **kwargs):
existing_user = None
if existing_user is not None:
profile = Profile.objects.get(user=existing_user)
for group in process_object.groups.all():
existing_user.groups.add(group)
else:
profile_serializer = ProfileSerializer(data=profile_data)
profile_serializer.is_valid(raise_exception=True)
Expand Down

0 comments on commit 6b1bca0

Please sign in to comment.