mirror of
https://github.com/bitwarden/server
synced 2025-12-17 08:43:27 +00:00
prevent duplicate invite accepts
This commit is contained in:
@@ -940,6 +940,12 @@ namespace Bit.Core.Services
|
||||
}
|
||||
}
|
||||
|
||||
var existingOrgUser = await _organizationUserRepository.GetByOrganizationAsync(orgUser.OrganizationId, user.Email);
|
||||
if(existingOrgUser != null)
|
||||
{
|
||||
throw new BadRequestException("You are already part of this organization.");
|
||||
}
|
||||
|
||||
var tokenValidationFailed = true;
|
||||
try
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user