-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[PM-15637] Notify Custom Users with “Manage Account Recovery” permission for Device Approval Requests #5359
Conversation
… ManageResetPassword permission
…d validate notification email recipients
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #5359 +/- ##
==========================================
- Coverage 44.22% 44.22% -0.01%
==========================================
Files 1492 1492
Lines 68869 68911 +42
Branches 6203 6203
==========================================
+ Hits 30460 30475 +15
- Misses 37089 37116 +27
Partials 1320 1320 ☔ View full report in Codecov by Sentry. |
New Issues (4)Checkmarx found the following issues in this Pull Request
Fixed Issues (7)Great job! The following issues were fixed in this Pull Request
|
@@ -297,10 +297,34 @@ private async Task NotifyAdminsOfDeviceApprovalRequestAsync(OrganizationUser org | |||
return; | |||
} | |||
|
|||
var admins = await _organizationUserRepository.GetManyByMinimumRoleAsync( | |||
var adminEmails = await GetAdminAndAccountRecoveryEmailsAsync(organizationUser.OrganizationId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
None-blocking question: I guess it's safe to say that adminEmails
will never be empty because an organization will have at least one owner?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, exactly! We always check if an organization has at least one confirmed owner when updating/removing a user.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Looks good, also curious about the answer to JimmyVo16's question.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
…mail-notification-for-device-approval-requests
|
🎟️ Tracking
https://bitwarden.atlassian.net/browse/PM-15637
📔 Objective
While testing #5270 it was noticed that notifications were missing for Custom Users with “Manage Account Recovery” permission
⏰ Reminders before review
🦮 Reviewer guidelines
:+1:
) or similar for great changes:memo:
) or ℹ️ (:information_source:
) for notes or general info:question:
) for questions:thinking:
) or 💭 (:thought_balloon:
) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion:art:
) for suggestions / improvements:x:
) or:warning:
) for more significant problems or concerns needing attention:seedling:
) or ♻️ (:recycle:
) for future improvements or indications of technical debt:pick:
) for minor or nitpick changes