From bd7d95a57693e9c40d687faaba3cb54f0f2ac9fe Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Thu, 21 Dec 2006 08:43:55 +0000 Subject: [PATCH] Prevent Item.save() from running when hitting Escape in an empty field (I don't know when this started, but Beta 2 didn't do it...) --- chrome/content/zotero/xpcom/data_access.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chrome/content/zotero/xpcom/data_access.js b/chrome/content/zotero/xpcom/data_access.js index 87d721750..97fd8aafe 100644 --- a/chrome/content/zotero/xpcom/data_access.js +++ b/chrome/content/zotero/xpcom/data_access.js @@ -424,7 +424,7 @@ Zotero.Item.prototype.setField = function(field, value, loadIn){ 'setField'); } - if (this._data[field] && this._data[field]==value){ + if (this._data[field] != undefined && this._data[field]==value){ return false; } this._data[field] = value;