fix: zusätzlichen Löschfall in der GroupRepository-DeleteAsync-Methode behandeln.

This commit is contained in:
Developer 02 2024-10-30 16:01:21 +01:00
parent 9f99bb0bc9
commit 4c02607409

View File

@ -23,10 +23,14 @@ namespace DigitalData.UserManager.Infrastructure.Repositories
var gou_list = await _gouRepo.ReadAsync(readOnly: false, groupId: group.Id);
if (gou_list.Any())
_dbContext.RemoveRange(gou_list);
var uRep_list = await _uRepRepo.ReadAllAsync(groupId: group.Id);
if (uRep_list.Any())
_dbContext.RemoveRange(uRep_list);
var ur_list = await _uRepRepo.ReadAllAsync(groupId: group.Id);
if (ur_list.Any())
_dbContext.RemoveRange(ur_list);
uRep_list = await _uRepRepo.ReadAllAsync(repGroupId: group.Id);
if (uRep_list.Any())
_dbContext.RemoveRange(uRep_list);
return await base.DeleteAsync(group);
}