mirror of
https://github.com/bitwarden/browser
synced 2025-12-10 13:23:34 +00:00
null checks on query param sub
This commit is contained in:
2
jslib
2
jslib
Submodule jslib updated: cb7336c0e8...cbcf0adad5
@@ -29,7 +29,9 @@ export class FolderAddEditComponent extends BaseFolderAddEditComponent {
|
||||
this.folderId = params.folderId;
|
||||
}
|
||||
await super.ngOnInit();
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -66,7 +66,9 @@ export class AddEditComponent extends BaseAddEditComponent {
|
||||
this.cipher.login.uris[0].uri = params.uri;
|
||||
}
|
||||
}
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
|
||||
window.setTimeout(() => {
|
||||
|
||||
@@ -26,7 +26,9 @@ export class AttachmentsComponent extends BaseAttachmentsComponent {
|
||||
const queryParamsSub = this.route.queryParams.subscribe(async (params) => {
|
||||
this.cipherId = params.cipherId;
|
||||
await super.ngOnInit();
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -131,7 +131,9 @@ export class CiphersComponent extends BaseCiphersComponent implements OnInit, On
|
||||
window.setTimeout(() => this.popupUtils.setContentScrollY(window, this.state.scrollY), 0);
|
||||
}
|
||||
this.stateService.remove(ComponentId);
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
|
||||
this.broadcasterService.subscribe(ComponentId, (message: any) => {
|
||||
|
||||
@@ -27,7 +27,9 @@ export class CollectionsComponent extends BaseCollectionsComponent {
|
||||
const queryParamsSub = this.route.queryParams.subscribe(async (params) => {
|
||||
this.cipherId = params.cipherId;
|
||||
await super.ngOnInit();
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -132,7 +132,9 @@ export class GroupingsComponent extends BaseGroupingsComponent implements OnInit
|
||||
if (!this.syncService.syncInProgress || restoredScopeState) {
|
||||
window.setTimeout(() => this.popupUtils.setContentScrollY(window, this.state.scrollY), 0);
|
||||
}
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -30,7 +30,9 @@ export class PasswordHistoryComponent extends BasePasswordHistoryComponent {
|
||||
}
|
||||
|
||||
await super.ngOnInit();
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -32,7 +32,9 @@ export class ShareComponent extends BaseShareComponent {
|
||||
const queryParamsSub = this.route.queryParams.subscribe(async (params) => {
|
||||
this.cipherId = params.cipherId;
|
||||
await super.ngOnInit();
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -50,7 +50,9 @@ export class ViewComponent extends BaseViewComponent {
|
||||
}
|
||||
|
||||
await this.load();
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
}
|
||||
});
|
||||
super.ngOnInit();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user