ui-sortable icon indicating copy to clipboard operation
ui-sortable copied to clipboard

_connectedSortables is null

Open rbedger opened this issue 10 years ago • 4 comments

callbacks.update

var droptargetScope = getElementScope(ui.item.sortable._connectedSortables, droptarget);
ui.item.sortable.droptargetModel = droptargetScope.ngModel;

Upon dropping an item into a connected sortable, the above code throws an exception because _connectedSortables is null. It doesn't seem to end up affecting anything because wrapping it in an if block still works:

if (ui.item.sortable._connectedSortables){ 
    var droptargetScope = getElementScope(ui.item.sortable._connectedSortables, droptarget);
    ui.item.sortable.droptargetModel = droptargetScope.ngModel;
}

rbedger avatar Mar 30 '16 12:03 rbedger

Thanks for reporting! What version are you using?

Interestingly, I couldn't reproduce using the connected sortables example from README (http://codepen.io/thgreasi/pen/uFile). Any change you can share a codepen example of your use case?

Thodoris Greasidis Computer, Networking & Communications Engineer

thgreasi avatar Mar 30 '16 13:03 thgreasi

I'll see if I can get it to replicate outside of our environment

On Wed, Mar 30, 2016 at 9:01 AM Thodoris Greasidis [email protected] wrote:

Thanks for reporting! What version are you using?

Interestingly, I couldn't reproduce using the connected sortables example from README (http://codepen.io/thgreasi/pen/uFile). Any change you can share a codepen example of your use case?

Thodoris Greasidis Computer, Networking & Communications Engineer

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/angular-ui/ui-sortable/issues/447#issuecomment-203421398

rbedger avatar Mar 30 '16 14:03 rbedger

@rbedger Any feedback on this?

thgreasi avatar Apr 07 '16 14:04 thgreasi

Closing this for now. Please re-open if you find anything more on this.

thgreasi avatar Apr 17 '16 18:04 thgreasi