mirror of
https://github.com/aliasvault/aliasvault.git
synced 2026-03-11 19:30:29 -04:00
Unblock admin user when a password request has been requested (#876)
This commit is contained in:
committed by
Leendert de Borst
parent
f148ccdeba
commit
fa2dedb05a
@@ -53,6 +53,11 @@ public static class StartupTasks
|
||||
await userManager.CreateAsync(adminUser);
|
||||
adminUser.PasswordHash = adminPasswordHash;
|
||||
adminUser.LastPasswordChanged = DateTime.UtcNow;
|
||||
|
||||
// During password reset, also unblock the admin user in case it was blocked.
|
||||
adminUser.LockoutEnabled = false;
|
||||
adminUser.LockoutEnd = null;
|
||||
|
||||
await userManager.UpdateAsync(adminUser);
|
||||
|
||||
Console.WriteLine("Admin user created.");
|
||||
|
||||
Reference in New Issue
Block a user