Skip to content

Commit 5e4f1b8

Browse files
porterclevJasonKimy
andcommitted
Datepicker: removes div when destroyed
Co-authored-by: DawnSovereign <jason.t.kim2@gmail.com>
1 parent d19d80e commit 5e4f1b8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ui/widgets/datepicker.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,6 @@ $.extend( Datepicker.prototype, {
423423

424424
nodeName = target.nodeName.toLowerCase();
425425
$.removeData( target, "datepicker" );
426-
$.datepicker._hideDatepicker();
427426
if ( nodeName === "input" ) {
428427
inst.append.remove();
429428
inst.trigger.remove();
@@ -436,9 +435,11 @@ $.extend( Datepicker.prototype, {
436435
$target.removeClass( this.markerClassName ).empty();
437436
}
438437

438+
inst.dpDiv.remove();
439439
if ( datepicker_instActive === inst ) {
440440
datepicker_instActive = null;
441441
this._curInst = null;
442+
this.dpDiv = null;
442443
}
443444
},
444445

0 commit comments

Comments
 (0)