Ticket #5288 (closed bug: duplicate)

Opened 3 years ago

Last modified 3 years ago

opening ui dialog does not work for the second time

Reported by: Gruewo Owned by:
Priority: blocker Milestone: 1.8
Component: ui.dialog Version: 1.8rc3
Keywords: Cc:
Blocking: Blocked by:

Description

At first I tried to reopen  http://dev.jqueryui.com/ticket/5185 - but I don't have permission to do so...
(related to changeset  http://dev.jqueryui.com/changeset/3823)

as we updated from jquery ui 1.7.2 to 1.8rc3 we noticed that the dialog widget does not work for the second time opened(1, 3-... times work).

tracking the error down we found out that it happens in the line:

625: var $el = (this.oldInstances.length ? this.oldInstances.splice(0, 1)[0] : $('<div></div>').addClass('ui-widget-overlay'))

the problem is that the oldInstances array contains a valid element (used for the first opening of the dialog) and a second element that has the value undefined - and this is the problem as the above expression tries to call .appendTo(document.body) on the array element

Change History

comment:1 Changed 3 years ago by scott.gonzalez

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

Duplicate of #5228.

Note: See TracTickets for help on using tickets.