Skip to content

Commit 0e4eabf

Browse files
committed
#1611: Remove MultiDrag events on GLOBAL destroy
1 parent c3d1ea7 commit 0e4eabf

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

plugins/MultiDrag/MultiDrag.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ function MultiDragPlugin() {
456456
multiDragClones.length = 0;
457457
},
458458

459-
destroy() {
459+
destroyGlobal() {
460460
this._deselectMultiDrag();
461461
off(document, 'pointerup', this._deselectMultiDrag);
462462
off(document, 'mouseup', this._deselectMultiDrag);

src/Sortable.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1284,7 +1284,7 @@ Sortable.prototype = /** @lends Sortable.prototype */ {
12841284
evt
12851285
});
12861286

1287-
parentEl = dragEl.parentNode;
1287+
parentEl = dragEl && dragEl.parentNode;
12881288

12891289
// Get again after plugin event
12901290
newIndex = index(dragEl);

0 commit comments

Comments
 (0)