Skip to content
This repository was archived by the owner on May 14, 2025. It is now read-only.

Commit d071207

Browse files
committed
Removes dashboard item poller when dashboard item is removed.
resolves #460
1 parent 2586acf commit d071207

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

ui/src/app/analytics/analytics.service.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,7 @@ export class AnalyticsService {
188188
if (!this.dashboardItems || this.dashboardItems.length === 0) {
189189
return;
190190
}
191+
this.stopPollingOfSingleDashboardItem(this.dashboardItems[index]);
191192
this.dashboardItems.splice(index, 1);
192193
}
193194

@@ -216,6 +217,9 @@ export class AnalyticsService {
216217
}
217218

218219
resetDashboard() {
220+
for (const dashboardItemToDisable of this.dashboardItems) {
221+
this.stopPollingOfSingleDashboardItem(dashboardItemToDisable);
222+
}
219223
this.dashboardItems.length = 0;
220224
this.addNewDashboardItem();
221225
}

0 commit comments

Comments
 (0)