1
0
mirror of https://github.com/bitwarden/server synced 2025-12-20 10:13:39 +00:00

[EC-388] Enforce organization policies when restoring user (#2152)

This commit is contained in:
Thomas Rittson
2022-08-03 07:09:22 +10:00
committed by GitHub
parent da3a3de7f2
commit ebdd30f5d4
8 changed files with 158 additions and 12 deletions

View File

@@ -193,7 +193,7 @@ namespace Bit.Scim.Controllers.v2
if (model.Active && orgUser.Status == OrganizationUserStatusType.Revoked)
{
await _organizationService.RestoreUserAsync(orgUser, null);
await _organizationService.RestoreUserAsync(orgUser, null, _userService);
}
else if (!model.Active && orgUser.Status != OrganizationUserStatusType.Revoked)
{
@@ -229,7 +229,7 @@ namespace Bit.Scim.Controllers.v2
var active = activeProperty.GetBoolean();
if (active && orgUser.Status == OrganizationUserStatusType.Revoked)
{
await _organizationService.RestoreUserAsync(orgUser, null);
await _organizationService.RestoreUserAsync(orgUser, null, _userService);
operationHandled = true;
}
else if (!active && orgUser.Status != OrganizationUserStatusType.Revoked)