Skip to content

Commit

Permalink
fix the item being closed after swiping it twice
Browse files Browse the repository at this point in the history
  • Loading branch information
Giorgi Pirtskhalaishvili committed Sep 2, 2023
1 parent 9ab28f3 commit 025bea6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/SwipeableFlatList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const SwipeableFlatList = <T,>({
if (!enableOpenMultipleRows) {
if (typeof openedRowIndex.current === 'number') {
const previousSwipeable = swipeableRefs.current[openedRowIndex.current];
if (previousSwipeable) {
if (previousSwipeable && previousSwipeable !== swipeable) {
previousSwipeable.close();
}
}
Expand Down

0 comments on commit 025bea6

Please sign in to comment.