Skip to content

Commit

Permalink
Correctly determine if element should be moved or cloned
Browse files Browse the repository at this point in the history
  • Loading branch information
stevebeller committed Aug 21, 2017
1 parent 6e401c7 commit 34d2302
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion angular-legacy-sortable.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@

removed = prevItems[oldIndex];

if (evt.clone) {
if (Sortable.active && Sortable.active.lastPullMode === 'clone') {
removed = angular.copy(removed);
prevItems.splice(Sortable.utils.index(evt.clone, sortable.options.draggable), 0, prevItems.splice(oldIndex, 1)[0]);

Expand Down

0 comments on commit 34d2302

Please sign in to comment.