navigate in zone

This commit is contained in:
Kyle Spearrin 2019-08-16 20:48:01 -04:00
parent 30a77e0c43
commit 206530a940
2 changed files with 4 additions and 3 deletions

View File

@ -56,7 +56,6 @@ export default class RuntimeBackground {
if (this.isSafari) {
// Reload the popup when it's opened
// TODO
/*
this.runtime.addEventListener('popover', (event: any) => {
const win: Window = event.target.contentWindow;

View File

@ -100,7 +100,7 @@ export class AppComponent implements OnInit {
});
this.changeDetectorRef.detectChanges();
});
} else if (msg.command === 'authBlocked') {
} else if (msg.command === 'authBlocked') {
this.ngZone.run(() => {
this.router.navigate(['home']);
});
@ -128,7 +128,9 @@ export class AppComponent implements OnInit {
window.setTimeout(() => BrowserApi.reloadExtension(window), 2000);
}
} else if (msg.command === 'reloadPopup') {
this.router.navigate(['/']);
this.ngZone.run(() => {
this.router.navigate(['/']);
});
} else {
msg.webExtSender = sender;
this.broadcasterService.send(msg);