diff --git a/src/angular/components/two-factor.component.ts b/src/angular/components/two-factor.component.ts index 709ce2d4db..0221bceede 100644 --- a/src/angular/components/two-factor.component.ts +++ b/src/angular/components/two-factor.component.ts @@ -197,12 +197,12 @@ export class TwoFactorComponent implements OnInit, OnDestroy { this.onSuccessfulLogin(); } this.platformUtilsService.eventTrack('Logged In From Two-step'); + if (response.resetMasterPassword) { + this.successRoute = 'set-password'; + } if (this.onSuccessfulLoginNavigate != null) { this.onSuccessfulLoginNavigate(); } else { - if (response.resetMasterPassword) { - this.successRoute = 'set-password'; - } this.router.navigate([this.successRoute], { queryParams: { identifier: this.identifier,