commit d50b6667f0201dac0a46b8ef4ea4c50828b49d5b
parent bdd69d0a53f7ad904c7e181436004e80af790706
Author: Dan Stillman <dstillman@zotero.org>
Date: Mon, 16 Mar 2015 23:50:24 -0400
Fix moving items to trash (from bf36a988e4)
Diffstat:
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/chrome/content/zotero/xpcom/data/item.js b/chrome/content/zotero/xpcom/data/item.js
@@ -77,7 +77,6 @@ Zotero.Item = function(itemTypeOrID) {
this._fileExists = null;
this._deleted = null;
- this._publication = null;
this._hasNote = null;
this._noteAccessTime = null;
@@ -1057,8 +1056,8 @@ Zotero.Item.prototype.removeCreator = function(orderIndex, allowMissing) {
}
-// Define 'deleted' and 'publication' properties
-for (let name of ['deleted', 'publication']) {
+// Define 'deleted' property (and any others that follow the same pattern in the future)
+for (let name of ['deleted']) {
let prop = '_' + name;
Zotero.defineProperty(Zotero.Item.prototype, name, {
@@ -1079,7 +1078,7 @@ for (let name of ['deleted', 'publication']) {
+ " state hasn't changed for item " + this.id);
return;
}
- this._markFieldChange('publication', !!this[prop]);
+ this._markFieldChange(name, !!this[prop]);
this._changed[name] = true;
this[prop] = val;
}