mirror of
https://github.com/bitwarden/browser
synced 2026-01-06 10:33:57 +00:00
Move policy checks within policyService (#1149)
* Refactor: use new policyService methods * Update jslib
This commit is contained in:
@@ -136,8 +136,9 @@ export class PeopleComponent extends BasePeopleComponent<OrganizationUserUserDet
|
||||
}
|
||||
|
||||
async load() {
|
||||
const policies = await this.policyService.getAll(PolicyType.ResetPassword);
|
||||
this.orgResetPasswordPolicyEnabled = policies.some(p => p.organizationId === this.organizationId && p.enabled);
|
||||
const resetPasswordPolicy = await this.policyService.getPolicyForOrganization(PolicyType.ResetPassword,
|
||||
this.organizationId);
|
||||
this.orgResetPasswordPolicyEnabled = resetPasswordPolicy?.enabled;
|
||||
super.load();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user