little modifications to users
This commit is contained in:
@ -38,11 +38,12 @@ namespace UserService.DatabaseLayer.Repository
|
||||
await db.SaveChangesAsync(token);
|
||||
}
|
||||
|
||||
public async Task UpdateAsync(T entity, CancellationToken token = default)
|
||||
public async Task<bool> UpdateAsync(T entity, CancellationToken token = default)
|
||||
{
|
||||
await using var db = new UserServiceDbContext();
|
||||
Context(db).Update(entity);
|
||||
await db.SaveChangesAsync(token);
|
||||
var items= await db.SaveChangesAsync(token);
|
||||
return items > 0;
|
||||
}
|
||||
|
||||
public async Task DeleteAsync(T entity, CancellationToken token = default)
|
||||
|
Reference in New Issue
Block a user