diff --git a/chrome/content/zotero/xpcom/integration.js b/chrome/content/zotero/xpcom/integration.js index 1e5e9ee2a..23e713d02 100644 --- a/chrome/content/zotero/xpcom/integration.js +++ b/chrome/content/zotero/xpcom/integration.js @@ -1142,7 +1142,9 @@ Zotero.Integration.Fields.prototype.addField = function(note) { if(field) { if(!this._doc.displayAlert(Zotero.getString("integration.replace"), Components.interfaces.zoteroIntegrationDocument.DIALOG_ICON_STOP, - Components.interfaces.zoteroIntegrationDocument.DIALOG_BUTTONS_OK_CANCEL)) return false; + Components.interfaces.zoteroIntegrationDocument.DIALOG_BUTTONS_OK_CANCEL)) { + throw new Zotero.Integration.UserCancelledException; + } } if(!field) { @@ -1653,9 +1655,6 @@ Zotero.Integration.Fields.prototype.addEditCitation = function(field, callback) } else { newField = true; var field = this.addField(true); - if(!field) { - throw new Zotero.Integration.UserCancelledException; - } } if(!citation) {