creating UpdateLoginEndpoint.cs
This commit is contained in:
@@ -3,6 +3,7 @@ using ApiEfCoreLibrary.DTO.Login.Response;
|
||||
using ApiEfCoreLibrary.DTO.Book.Response;
|
||||
using FastEndpoints;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using PasswordGenerator;
|
||||
|
||||
namespace ApiEfCoreLibrary.Endpoints.Login;
|
||||
|
||||
@@ -23,7 +24,7 @@ public class UpdateLoginEndpoint(LibraryDbContext database) : Endpoint<UpdateLog
|
||||
return;
|
||||
}
|
||||
|
||||
string? salt = BCrypt.Net.BCrypt.GenerateSalt(24);
|
||||
string? salt = new Password().IncludeLowercase().IncludeUppercase().IncludeNumeric().LengthRequired(24).Next();
|
||||
|
||||
login.Username = req.Username;
|
||||
login.FullName = req.FullName;
|
||||
|
Reference in New Issue
Block a user