From 9b231169b2efedba12ab5214ea5bb05251912cf7 Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Fri, 1 Apr 2016 02:00:12 -0400 Subject: [PATCH] Return the new item from ZoteroPane.duplicateSelectedItem() --- chrome/content/zotero/zoteroPane.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/chrome/content/zotero/zoteroPane.js b/chrome/content/zotero/zoteroPane.js index 75d47e482a..010370df51 100644 --- a/chrome/content/zotero/zoteroPane.js +++ b/chrome/content/zotero/zoteroPane.js @@ -1614,7 +1614,7 @@ var ZoteroPane = new function() /** - * @return {Promise} + * @return {Promise} - The new Zotero.Item */ this.duplicateSelectedItem = Zotero.Promise.coroutine(function* () { var self = this; @@ -1636,6 +1636,8 @@ var ZoteroPane = new function() }); yield self.selectItem(newItem.id); + + return newItem; });