1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-04 01:22:50 -05:00

[PM-1033] feat: auto accept invitation when enrolling into password reset

This commit is contained in:
Andreas Coroiu
2023-06-28 14:48:12 +02:00
parent b0392972fd
commit b7ca8d09a1
3 changed files with 28 additions and 4 deletions

View File

@ -213,7 +213,7 @@ public class OrganizationUsersController : Controller
if (useMasterPasswordPolicy)
{
await _organizationService.UpdateUserResetPasswordEnrollmentAsync(orgId, user.Id, model.ResetPasswordKey, user.Id);
await _organizationService.UpdateUserResetPasswordEnrollmentAsync(orgId, user.Id, model.ResetPasswordKey, _userService, user.Id);
}
}
@ -315,7 +315,7 @@ public class OrganizationUsersController : Controller
var callingUserId = user.Id;
await _organizationService.UpdateUserResetPasswordEnrollmentAsync(
new Guid(orgId), new Guid(userId), model.ResetPasswordKey, callingUserId);
new Guid(orgId), new Guid(userId), model.ResetPasswordKey, _userService, callingUserId);
}
[HttpPut("{id}/reset-password")]