Dialog: Fix removal of event listener for modal dialogs

Fixes #13649
This commit is contained in:
Scott González 2015-07-17 11:00:44 -04:00
parent f7ee8524b3
commit 62446d957e

View File

@ -860,9 +860,8 @@ $.widget( "ui.dialog", {
var overlays = this.document.data( "ui-dialog-overlays" ) - 1;
if ( !overlays ) {
this.document
.off( "focusin" )
.removeData( "ui-dialog-overlays" );
this._off( this.document, "focusin" );
this.document.removeData( "ui-dialog-overlays" );
} else {
this.document.data( "ui-dialog-overlays", overlays );
}