mirror of
https://github.com/bitwarden/browser
synced 2025-12-10 21:33:27 +00:00
Fix undefined variable error in desktop (#470)
This commit is contained in:
@@ -5,6 +5,8 @@ import {
|
||||
Router,
|
||||
} from '@angular/router';
|
||||
|
||||
import { first } from 'rxjs/operators';
|
||||
|
||||
import { TwoFactorProviderType } from 'jslib-common/enums/twoFactorProviderType';
|
||||
|
||||
import { TwoFactorEmailRequest } from 'jslib-common/models/request/twoFactorEmailRequest';
|
||||
@@ -65,14 +67,10 @@ export class TwoFactorComponent implements OnInit, OnDestroy {
|
||||
return;
|
||||
}
|
||||
|
||||
const queryParamsSub = this.route.queryParams.subscribe(async qParams => {
|
||||
this.route.queryParams.pipe(first()).subscribe(qParams => {
|
||||
if (qParams.identifier != null) {
|
||||
this.identifier = qParams.identifier;
|
||||
}
|
||||
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
|
||||
if (this.needsLock) {
|
||||
|
||||
Reference in New Issue
Block a user