From: XhmikosR Date: Fri, 18 Sep 2020 07:22:24 +0000 (+0300) Subject: Dropdown: fix variable always evaluating to true (#31673) X-Git-Tag: v4.5.3~37 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dc2f1e68cd3214047ec7b88cf060daf7152ee408;p=thirdparty%2Fbootstrap.git Dropdown: fix variable always evaluating to true (#31673) --- diff --git a/js/src/dropdown.js b/js/src/dropdown.js index 8cfa5564ab..5e3ed4c56e 100644 --- a/js/src/dropdown.js +++ b/js/src/dropdown.js @@ -469,7 +469,7 @@ class Dropdown { event.preventDefault() event.stopPropagation() - if (!isActive || isActive && (event.which === ESCAPE_KEYCODE || event.which === SPACE_KEYCODE)) { + if (!isActive || (event.which === ESCAPE_KEYCODE || event.which === SPACE_KEYCODE)) { if (event.which === ESCAPE_KEYCODE) { $(parent.querySelector(SELECTOR_DATA_TOGGLE)).trigger('focus') }