Skip to content

Commit

Permalink
fix(vx-drag): simplify handleDragEnd setState
Browse files Browse the repository at this point in the history
  • Loading branch information
Chris Williams committed Sep 18, 2019
1 parent 8d7e4b2 commit 73867f6
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions packages/vx-drag/src/Drag.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,7 @@ export default class Drag extends React.Component<DragProps, DragState> {
event.persist();

this.setState(
() => ({
isDragging: false,
}),
{ isDragging: false },
onDragEnd &&
(() => {
onDragEnd({ ...this.state, event });
Expand Down

0 comments on commit 73867f6

Please sign in to comment.