mirror of
https://github.com/Hopiu/bootstrap.git
synced 2026-04-04 13:30:24 +00:00
Modal: drop loop (#38368)
We only have two elements to iterate over so it doesn't make a lot of sense to use a loop here
This commit is contained in:
parent
c953096a40
commit
7a7fc1ad34
1 changed files with 3 additions and 3 deletions
|
|
@ -139,12 +139,12 @@ class Modal extends BaseComponent {
|
|||
}
|
||||
|
||||
dispose() {
|
||||
for (const htmlElement of [window, this._dialog]) {
|
||||
EventHandler.off(htmlElement, EVENT_KEY)
|
||||
}
|
||||
EventHandler.off(window, EVENT_KEY)
|
||||
EventHandler.off(this._dialog, EVENT_KEY)
|
||||
|
||||
this._backdrop.dispose()
|
||||
this._focustrap.deactivate()
|
||||
|
||||
super.dispose()
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue