2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-06-02 16:04:07 +03:00

Tooltip - check if tip and its parent node exist in dispose method (#32420)

This commit is contained in:
Rohit Sharma
2020-12-11 00:36:41 +05:30
committed by GitHub
parent 1edec546cb
commit 4535b09c46
2 changed files with 19 additions and 1 deletions
+1 -1
View File
@@ -222,7 +222,7 @@ class Tooltip extends BaseComponent {
EventHandler.off(this._element, this.constructor.EVENT_KEY)
EventHandler.off(this._element.closest(`.${CLASS_NAME_MODAL}`), 'hide.bs.modal', this._hideModalHandler)
if (this.tip) {
if (this.tip && this.tip.parentNode) {
this.tip.parentNode.removeChild(this.tip)
}