diff options
author | GeoSot <geo.sotis@gmail.com> | 2021-11-25 20:39:13 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-25 20:39:13 +0300 |
commit | 374eeecfbcabae20da08ce00d0f9268bb67b1e5e (patch) | |
tree | 7917e6bd3816dfb8872c54d0db8e5fffedde04d1 | |
parent | 91ad255e07d3d16f2ea88ca5b49bbe569ea5e2b4 (diff) |
tooltip.js: use array.includes instead of for iteration (#35127)
-rw-r--r-- | js/src/tooltip.js | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/js/src/tooltip.js b/js/src/tooltip.js index c845961011..bc59e6e946 100644 --- a/js/src/tooltip.js +++ b/js/src/tooltip.js @@ -598,13 +598,7 @@ class Tooltip extends BaseComponent { } _isWithActiveTrigger() { - for (const trigger in this._activeTrigger) { - if (this._activeTrigger[trigger]) { - return true - } - } - - return false + return Object.values(this._activeTrigger).includes(true) } _getConfig(config) { |