Fix RIS/BibTeX import errors when in library root
This commit is contained in:
parent
a455a72534
commit
19447e7b90
|
@ -646,7 +646,7 @@ Zotero.Server.Connector.Import.prototype = {
|
||||||
var { library, collection, editable } = Zotero.Server.Connector.getSaveTarget();
|
var { library, collection, editable } = Zotero.Server.Connector.getSaveTarget();
|
||||||
let arg = {};
|
let arg = {};
|
||||||
if (editable) {
|
if (editable) {
|
||||||
arg = {libraryID: library.libraryID, collections: [collection.id]};
|
arg = { libraryID: library.libraryID, collections: collection ? [collection.id] : null };
|
||||||
}
|
}
|
||||||
let items = yield translate.translate(arg);
|
let items = yield translate.translate(arg);
|
||||||
return [201, "application/json", JSON.stringify(items)];
|
return [201, "application/json", JSON.stringify(items)];
|
||||||
|
|
Loading…
Reference in New Issue
Block a user