* @param jQuery jqXHR
*/
_success: function(data, textStatus, jqXHR) {
- // initialize dialog content
- this._initDialog(data);
-
- // remove loading overlay
- this._content.removeClass('overlayLoading');
-
- if (this.options.success !== null && $.isFunction(this.options.success)) {
- this.options.success(data, textStatus, jqXHR);
+ if (this._isOpen) {
+ // initialize dialog content
+ this._initDialog(data);
+
+ // remove loading overlay
+ this._content.removeClass('overlayLoading');
+
+ if (this.options.success !== null && $.isFunction(this.options.success)) {
+ this.options.success(data, textStatus, jqXHR);
+ }
}
},