Ticket #4289 (closed bug: fixed)

Opened 6 years ago

Last modified 5 years ago

Draggable's "scope" option fails if no droppables currently exist

Reported by: NJBR Owned by:
Priority: major Milestone: 1.8
Component: ui.droppable Version: 1.7
Keywords: scope Cc:
Blocking: Blocked by:

Description

$.ui.ddmanager.prepareOffsets incorrectly assumes that droppables[scope] will always exist. This causes a failure if a draggable with scope defined is dragged when no accepting droppable is available. My fix is to add "
[]" to each case where droppables[scope] is referenced within ui.droppable.js

Current code:

var m = $.ui.ddmanager.droppables[t.options.scope];

Proposed change:

var m = $.ui.ddmanager.droppables[t.options.scope]
[];

There are three other locations within the file that would need this change.

Change History

comment:1 Changed 6 years ago by scott.gonzalez

  • Milestone changed from TBD to 1.8

comment:2 Changed 5 years ago by paul

  • Status changed from new to closed
  • Resolution set to fixed

fixed in r3107.

Note: See TracTickets for help on using tickets.