Password első felhasználó rögzítésénél hiba

This commit is contained in:
2026-01-21 12:59:56 +01:00
parent 6ea799dcdf
commit 0fd073755e
5 changed files with 10 additions and 5 deletions
+2 -2
View File
@@ -141,7 +141,7 @@ namespace WorkFlowCheck.BL.Services
var user = await _dbContext.Users
.Include(i => i.UserRoles)
.ThenInclude(i => i.Role)
.Where(w => w.UserName == userName)
.Where(w => w.UserName == userName && w.Active == true)
.FirstOrDefaultAsync();
if (user != null && PasswordHasher.VerifyPassword(user.PasswordHash, password))
{
@@ -400,7 +400,7 @@ namespace WorkFlowCheck.BL.Services
user.Active = userDTO.Active;
user.NFCActive = userDTO.NFCActive;
user.NFCCode = userDTO.NFCCode;
await _dbContext.SaveChangesAsync();
retVal = _mapper.Map<UserDTO>(user);