Fix Collections.getCollectionsContainingItems() when no ids are passed
Previously it would return all collections
This commit is contained in:
parent
c384fef867
commit
c61892e4b6
1 changed files with 1 additions and 0 deletions
|
@ -142,6 +142,7 @@ Zotero.Collections = function() {
|
|||
|
||||
|
||||
this.getCollectionsContainingItems = function (itemIDs, asIDs) {
|
||||
if (!itemIDs.length) return [];
|
||||
var sql = "SELECT collectionID FROM collections WHERE ";
|
||||
var sqlParams = [];
|
||||
for (let id of itemIDs) {
|
||||
|
|
Loading…
Add table
Reference in a new issue