From 37f566931923fda93994abba403e290974d05daa Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Thu, 7 May 2015 01:00:45 -0400 Subject: [PATCH] Fix making an item a child item if it's in any collections --- chrome/content/zotero/xpcom/data/item.js | 2 +- test/tests/itemTest.js | 36 ++++++++++++++++++++++++ 2 files changed, 37 insertions(+), 1 deletion(-) diff --git a/chrome/content/zotero/xpcom/data/item.js b/chrome/content/zotero/xpcom/data/item.js index cdd69197a2..964536e09f 100644 --- a/chrome/content/zotero/xpcom/data/item.js +++ b/chrome/content/zotero/xpcom/data/item.js @@ -1409,7 +1409,7 @@ Zotero.Item.prototype._saveData = Zotero.Promise.coroutine(function* (env) { let changedCollections = yield Zotero.DB.columnQueryAsync(sql, this.id); if (changedCollections.length) { let parentItem = yield this.ObjectsClass.getByLibraryAndKeyAsync( - this.libraryID, oldParentKey + this.libraryID, parentItemKey ) for (let i=0; i