diff options
author | GeoSot <geo.sotis@gmail.com> | 2022-03-10 01:38:17 +0300 |
---|---|---|
committer | XhmikosR <xhmikosr@gmail.com> | 2022-03-10 16:22:14 +0300 |
commit | 88da704eedc5149b70dcec7845453456a6e26761 (patch) | |
tree | 3ffdce0b721c7b1440611037843cfc3f700190a8 /js/src | |
parent | 28f150d7204788114e2b36555f5e07eb8bdfdbab (diff) |
Carousel: omit redundant checks as we are always transforming the right values
Diffstat (limited to 'js/src')
-rw-r--r-- | js/src/carousel.js | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/js/src/carousel.js b/js/src/carousel.js index 37ebde3fcc..70c5fd286a 100644 --- a/js/src/carousel.js +++ b/js/src/carousel.js @@ -389,10 +389,6 @@ class Carousel extends BaseComponent { } _directionToOrder(direction) { - if (![DIRECTION_RIGHT, DIRECTION_LEFT].includes(direction)) { - return direction - } - if (isRTL()) { return direction === DIRECTION_LEFT ? ORDER_PREV : ORDER_NEXT } @@ -401,10 +397,6 @@ class Carousel extends BaseComponent { } _orderToDirection(order) { - if (![ORDER_NEXT, ORDER_PREV].includes(order)) { - return order - } - if (isRTL()) { return order === ORDER_PREV ? DIRECTION_LEFT : DIRECTION_RIGHT } |