From 52e80dff03f6eff689a9b9d54eaee75c2f3712e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Krist=C3=B3f=20T=C3=B3th?= Date: Mon, 14 Oct 2019 14:58:40 +0200 Subject: [PATCH] Avoid polling iframe when url is not set --- src/app/dashboard/dashboard.component.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/app/dashboard/dashboard.component.ts b/src/app/dashboard/dashboard.component.ts index 8af2e67..89b5b5a 100644 --- a/src/app/dashboard/dashboard.component.ts +++ b/src/app/dashboard/dashboard.component.ts @@ -168,6 +168,10 @@ export class DashboardComponent implements OnInit, OnDestroy { errors.pipe( tap( response => { + if (this.iframeUrl.value === '') { + this.iframeReloadSubscription.unsubscribe(); + this.polling.next(false); + } if (response.status === 200) { this.iframeReloadSubscription.unsubscribe(); this.polling.next(false);