1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-10 21:33:27 +00:00

[PM-25922] Hotfix: Revert canManageDeviceApprovals (#16478)

This commit is contained in:
Jimmy Vo
2025-09-18 15:49:42 -04:00
committed by GitHub
parent 376d2d8bf7
commit 68d7cb4846
2 changed files with 1 additions and 28 deletions

View File

@@ -111,28 +111,6 @@ describe("Organization", () => {
expect(organization.canManageDeviceApprovals).toBe(false);
});
it("should return false when ssoEnabled is false", () => {
data.type = OrganizationUserType.Admin;
data.useSso = true;
data.ssoEnabled = false;
data.ssoMemberDecryptionType = MemberDecryptionType.TrustedDeviceEncryption;
const organization = new Organization(data);
expect(organization.canManageDeviceApprovals).toBe(false);
});
it("should return false when ssoMemberDecryptionType is not TrustedDeviceEncryption", () => {
data.type = OrganizationUserType.Admin;
data.useSso = true;
data.ssoEnabled = true;
data.ssoMemberDecryptionType = MemberDecryptionType.MasterPassword;
const organization = new Organization(data);
expect(organization.canManageDeviceApprovals).toBe(false);
});
it("should return true when admin has all required SSO settings enabled", () => {
data.type = OrganizationUserType.Admin;
data.useSso = true;

View File

@@ -309,12 +309,7 @@ export class Organization {
}
get canManageDeviceApprovals() {
return (
(this.isAdmin || this.permissions.manageResetPassword) &&
this.useSso &&
this.ssoEnabled &&
this.ssoMemberDecryptionType === MemberDecryptionType.TrustedDeviceEncryption
);
return (this.isAdmin || this.permissions.manageResetPassword) && this.useSso;
}
get isExemptFromPolicies() {