Return the new item from ZoteroPane.duplicateSelectedItem()

This commit is contained in:
Dan Stillman 2016-04-01 02:00:12 -04:00
parent 4566ff30f5
commit 9b231169b2

View file

@ -1614,7 +1614,7 @@ var ZoteroPane = new function()
/**
* @return {Promise}
* @return {Promise<Zotero.Item>} - 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;
});