Graph: Fixed graph tooltip getting stuck / not being cleared when leaving dashboard, fixes #23881 (#24162)

(cherry picked from commit f273e56adc)
This commit is contained in:
Torkel Ödegaard
2020-05-07 14:59:21 +02:00
committed by Arve Knudsen
parent a64ae3bad1
commit cbed026c4d
2 changed files with 1 additions and 3 deletions
@@ -467,6 +467,7 @@ export class PanelModel implements DataConfigSource {
}
destroy() {
this.events.emit(PanelEvents.panelTeardown);
this.events.removeAllListeners();
if (this.queryRunner) {
@@ -82,9 +82,6 @@ module.directive('grafanaPanel', ($rootScope, $document, $timeout) => {
scope.$on('$destroy', () => {
elem.off();
panel.events.emit(PanelEvents.panelTeardown);
panel.events.removeAllListeners();
if (panelScrollbar) {
panelScrollbar.dispose();
}