Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correctly determine if element should be moved or cloned #36

Merged
merged 1 commit into from
Nov 7, 2017

Conversation

Stevebel
Copy link

This is a fix for issue #34
It seems that evt.clone is always defined for onAdd events. This PR changes the logic to check Sortable.active.lastPullMode === 'clone' which I believe is the most reliable way to determine if the add was a clone or simply a move.

@samjacobclift
Copy link
Contributor

Good Job on the PR! it looks ok tbh, would it be too hard to add an e2e test for this change to ensure the behaviour works as expected? It doesn't have to be too complicated a test see here for an example. Will checkout your branch later too

@Stevebel
Copy link
Author

Will do

@bwegrzyn
Copy link

bwegrzyn commented Oct 4, 2017

Any chance this can be merged soon? I'm running in to this issue as well and looking for a fix.

@samjacobclift samjacobclift merged commit a78d2de into SortableJS:master Nov 7, 2017
@samjacobclift
Copy link
Contributor

deployed new version

@samjacobclift
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants