1
0
mirror of https://github.com/bitwarden/browser synced 2026-01-27 23:03:45 +00:00

[PM-27086] Remove redundant checks

This commit is contained in:
rr-bw
2026-01-22 15:07:30 -08:00
parent f57d2936bf
commit 342da61aa9

View File

@@ -131,19 +131,14 @@ export class SetInitialPasswordComponent implements OnInit {
FeatureFlag.EnableAccountEncryptionV2JitPasswordRegistration,
);
// // Scenario 1: KM flag ON
// Scenario 1: KM flag ON
if (accountEncryptionV2) {
await this.setInitialPasswordJitMPUserV2Encryption(passwordInputResult);
return;
}
// Scenario 2: KM flag OFF, Auth flag ON
if (
passwordInputResult.newApisWithInputPasswordFlagEnabled &&
!passwordInputResult.newMasterKey &&
!passwordInputResult.newServerMasterKeyHash &&
!passwordInputResult.newLocalMasterKeyHash
) {
if (passwordInputResult.newApisWithInputPasswordFlagEnabled) {
/**
* If the Auth flag is enabled, it means the InputPasswordComponent will not emit a newMasterKey,
* newServerMasterKeyHash, and newLocalMasterKeyHash. So we must create them here and add them late