aboutsummaryrefslogtreecommitdiff
path: root/js/src/toast.js
diff options
context:
space:
mode:
authorGeoSot <[email protected]>2021-04-11 09:54:48 +0300
committerGitHub <[email protected]>2021-04-11 09:54:48 +0300
commit566451230f5c87c3d7515af02995895df610b8ac (patch)
treedd270eb14c1c2d08840f41c4f6571d42ded605c8 /js/src/toast.js
parentbac0b0c899b8e7fbdbc1ec7fa1ac1c5b847b3c90 (diff)
downloadbootstrap-566451230f5c87c3d7515af02995895df610b8ac.tar.xz
bootstrap-566451230f5c87c3d7515af02995895df610b8ac.zip
Remove element event listeners through base component (#33429)
After some research, I found out that EventHandler saves all the custom events per element using namespace, and is capable of removing handlers using only the element and its namespace (`DATA_KEY`). So, probably is better to utilize the base-component to do the same job.
Diffstat (limited to 'js/src/toast.js')
-rw-r--r--js/src/toast.js2
1 files changed, 0 insertions, 2 deletions
diff --git a/js/src/toast.js b/js/src/toast.js
index 01b994e28..5d762b29d 100644
--- a/js/src/toast.js
+++ b/js/src/toast.js
@@ -156,8 +156,6 @@ class Toast extends BaseComponent {
this._element.classList.remove(CLASS_NAME_SHOW)
}
- EventHandler.off(this._element, EVENT_CLICK_DISMISS)
-
super.dispose()
this._config = null
}