Only allow users matching the team invite to accept, if the invite was specified for a user (rather than an email)
This commit is contained in:
parent
c5ca46a14b
commit
10faa7de84
7 changed files with 24 additions and 21 deletions
|
@ -215,7 +215,10 @@ class User(ApiResource):
|
|||
if parsed_invite is not None:
|
||||
if parsed_invite[0] == 'teaminvite':
|
||||
# Add the user to the team.
|
||||
try_accept_invite(invite_code, new_user)
|
||||
try:
|
||||
try_accept_invite(invite_code, new_user)
|
||||
except model.DataModelException:
|
||||
pass
|
||||
|
||||
return 'Created', 201
|
||||
except model.TooManyUsersException as ex:
|
||||
|
|
Reference in a new issue