1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-10 13:23:34 +00:00

fix: add guard for undefined SimpleChange (#15998)

This commit is contained in:
Stephon Brown
2025-08-14 11:48:00 -04:00
committed by GitHub
parent 66396a54c6
commit 642216a070

View File

@@ -153,7 +153,8 @@ export class ManageTaxInformationComponent implements OnInit, OnDestroy, OnChang
ngOnChanges(changes: SimpleChanges): void { ngOnChanges(changes: SimpleChanges): void {
// Clear the value of the tax-id if states have been changed in the parent component // Clear the value of the tax-id if states have been changed in the parent component
if (!changes.showTaxIdField.currentValue) { const showTaxIdField = changes["showTaxIdField"];
if (showTaxIdField && !showTaxIdField.currentValue) {
this.formGroup.controls.taxId.setValue(null); this.formGroup.controls.taxId.setValue(null);
} }
} }