Skip to content

Commit ecfb72c

Browse files
committed
when destroying InfoIcon, destroy the related hud and stop old listeners
1 parent 508ea8d commit ecfb72c

3 files changed

Lines changed: 4 additions & 2 deletions

File tree

src/web/assets/cp/dist/cp.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/web/assets/cp/dist/cp.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/web/assets/cp/src/js/InfoIcon.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,9 @@ Craft.InfoIcon = Garnish.Base.extend({
114114
},
115115

116116
destroy: function () {
117+
this.hud?.destroy();
117118
this.$icon.removeData('infoicon');
119+
this.removeAllListeners(this.$icon);
118120
this.base();
119121
},
120122
});

0 commit comments

Comments
 (0)