mirror of
https://github.com/twbs/bootstrap.git
synced 2025-01-17 09:52:29 +01:00
Remove nonsensical boolean check (#27787)
...as it always evaluates to true
This commit is contained in:
parent
fa03289d13
commit
c70b043a76
@ -468,8 +468,7 @@ class Dropdown {
|
||||
const parent = Dropdown._getParentFromElement(this)
|
||||
const isActive = $(parent).hasClass(ClassName.SHOW)
|
||||
|
||||
if (!isActive && (event.which !== ESCAPE_KEYCODE || event.which !== SPACE_KEYCODE) ||
|
||||
isActive && (event.which === ESCAPE_KEYCODE || event.which === SPACE_KEYCODE)) {
|
||||
if (!isActive || isActive && (event.which === ESCAPE_KEYCODE || event.which === SPACE_KEYCODE)) {
|
||||
if (event.which === ESCAPE_KEYCODE) {
|
||||
const toggle = parent.querySelector(Selector.DATA_TOGGLE)
|
||||
$(toggle).trigger('focus')
|
||||
|
Loading…
x
Reference in New Issue
Block a user