From: Niels Steenbeek Date: Tue, 10 Mar 2015 14:38:04 +0000 (+0100) Subject: Tooltip: Destroy $tip, $arrow, $viewport to avoid memory leak X-Git-Tag: v3.3.5~118 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7429fc7ff965147fe218b3b4e124d922b08118f2;p=thirdparty%2Fbootstrap.git Tooltip: Destroy $tip, $arrow, $viewport to avoid memory leak Closes #16039. --- diff --git a/js/tooltip.js b/js/tooltip.js index 27367880f7..789d04f7ab 100644 --- a/js/tooltip.js +++ b/js/tooltip.js @@ -440,6 +440,12 @@ clearTimeout(this.timeout) this.hide(function () { that.$element.off('.' + that.type).removeData('bs.' + that.type) + if (that.$tip) { + that.$tip.detach() + } + that.$tip = null + that.$arrow = null + that.$viewport = null }) }