mirror of
https://github.com/bitwarden/server.git
synced 2025-07-11 21:03:47 -05:00
Ac/pm 17449/add managed user validation to email token (#5437)
This commit is contained in:
@ -545,7 +545,7 @@ public class UserService : UserManager<User>, IUserService, IDisposable
|
||||
return IdentityResult.Failed(_identityErrorDescriber.PasswordMismatch());
|
||||
}
|
||||
|
||||
var managedUserValidationResult = await ValidateManagedUserAsync(user, newEmail);
|
||||
var managedUserValidationResult = await ValidateManagedUserDomainAsync(user, newEmail);
|
||||
|
||||
if (!managedUserValidationResult.Succeeded)
|
||||
{
|
||||
@ -617,7 +617,7 @@ public class UserService : UserManager<User>, IUserService, IDisposable
|
||||
return IdentityResult.Success;
|
||||
}
|
||||
|
||||
private async Task<IdentityResult> ValidateManagedUserAsync(User user, string newEmail)
|
||||
public async Task<IdentityResult> ValidateManagedUserDomainAsync(User user, string newEmail)
|
||||
{
|
||||
var managingOrganizations = await GetOrganizationsManagingUserAsync(user.Id);
|
||||
|
||||
|
Reference in New Issue
Block a user