mirror of
https://github.com/bitwarden/server.git
synced 2025-02-16 01:51:21 +01:00
Allow UpdateKeyAsync when user already has key
This commit is contained in:
parent
a9195942fd
commit
73cc221deb
@ -548,11 +548,6 @@ namespace Bit.Core.Services
|
||||
|
||||
if(await CheckPasswordAsync(user, masterPassword))
|
||||
{
|
||||
if(!string.IsNullOrWhiteSpace(user.Key))
|
||||
{
|
||||
throw new BadRequestException("User already has an updated encryption key.");
|
||||
}
|
||||
|
||||
user.RevisionDate = user.AccountRevisionDate = DateTime.UtcNow;
|
||||
user.SecurityStamp = Guid.NewGuid().ToString();
|
||||
user.Key = key;
|
||||
|
Loading…
Reference in New Issue
Block a user