mirror of
https://github.com/bitwarden/browser
synced 2025-12-10 05:13:29 +00:00
[PM-26929] filter at risk passwords count to only critical apps (#16879)
* filter at risk passwords count to only critical apps * PM-26929 assign tasks to those apps that are marked as critical --------- Co-authored-by: voommen-livefront <voommen@livefront.com>
This commit is contained in:
@@ -76,12 +76,9 @@ export class AllActivitiesService {
|
||||
}
|
||||
|
||||
setAllAppsReportDetails(applications: ApplicationHealthReportDetailEnriched[]) {
|
||||
// Only count at-risk passwords for CRITICAL applications
|
||||
const criticalApps = applications.filter((app) => app.isMarkedAsCritical);
|
||||
const totalAtRiskPasswords = criticalApps.reduce(
|
||||
(sum, app) => sum + app.atRiskPasswordCount,
|
||||
0,
|
||||
);
|
||||
const totalAtRiskPasswords = applications
|
||||
.filter((app) => app.isMarkedAsCritical)
|
||||
.reduce((sum, app) => sum + app.atRiskPasswordCount, 0);
|
||||
this.atRiskPasswordsCountSubject$.next(totalAtRiskPasswords);
|
||||
|
||||
this.allApplicationsDetailsSubject$.next(applications);
|
||||
|
||||
Reference in New Issue
Block a user