mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-10 23:54:08 +02:00
Return a new function with Util.noop
This commit is contained in:
@@ -322,7 +322,7 @@ class Tooltip {
|
||||
// https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html
|
||||
if ('ontouchstart' in document.documentElement) {
|
||||
Util.makeArray(document.body.children).forEach((element) => {
|
||||
EventHandler.on(element, 'mouseover', Util.noop)
|
||||
EventHandler.on(element, 'mouseover', Util.noop())
|
||||
})
|
||||
}
|
||||
|
||||
@@ -381,7 +381,7 @@ class Tooltip {
|
||||
// empty mouseover listeners we added for iOS support
|
||||
if ('ontouchstart' in document.documentElement) {
|
||||
Util.makeArray(document.body.children)
|
||||
.forEach((element) => EventHandler.off(element, 'mouseover', Util.noop))
|
||||
.forEach((element) => EventHandler.off(element, 'mouseover', Util.noop()))
|
||||
}
|
||||
|
||||
this._activeTrigger[Trigger.CLICK] = false
|
||||
|
@@ -235,8 +235,9 @@ const Util = {
|
||||
return Util.findShadowRoot(element.parentNode)
|
||||
},
|
||||
|
||||
// eslint-disable-next-line no-empty-function
|
||||
noop() {
|
||||
// eslint-disable-next-line no-empty-function
|
||||
return function () {}
|
||||
},
|
||||
|
||||
get jQuery() {
|
||||
|
Reference in New Issue
Block a user