Fix some issues with corrupted field codes

This commit is contained in:
Simon Kornblith 2012-05-03 15:40:53 -04:00
parent 4bb7f7d08b
commit 47c4f686e8

View file

@ -1323,9 +1323,13 @@ Zotero.Integration.Fields.prototype._showCorruptFieldError = function(e, field,
// Display reselect edit citation dialog
var me = this;
var oldWindow = Zotero.Integration.currentWindow;
var oldProgressCallback = me.progressCallback;
this.addEditCitation(field, function() {
Zotero.Integration.currentWindow.close();
if(Zotero.Integration.currentWindow && !Zotero.Integration.currentWindow.closed) {
Zotero.Integration.currentWindow.close();
}
Zotero.Integration.currentWindow = oldWindow;
me.progressCallback = oldProgressCallback;
me.updateSession(callback, errorCallback);
});
return false;