Skip to content

Commit

Permalink
use .slice when .toArray is not present
Browse files Browse the repository at this point in the history
  • Loading branch information
artemgurzhii authored Sep 9, 2024
1 parent 2f4b254 commit ad1c4de
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ember-drag-drop/src/services/drag-coordinator.js
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ export default Service.extend({

let list = aSortable.get('sortableObjectList');
if (!this.get('inPlace')) {
list = A(list.toArray());
list = A(list.toArray ? list.toArray() : list.slice());
}

if (this.get('useSwap')) {
Expand Down

0 comments on commit ad1c4de

Please sign in to comment.