Allow parentID in importFileAttachment() test support function
The Zotero.Attachments functions only take parentItemID, but createDataObject() takes parentID.
This commit is contained in:
parent
94c4445475
commit
687f86af71
1 changed files with 2 additions and 1 deletions
|
@ -844,7 +844,8 @@ function importFileAttachment(filename, options = {}) {
|
|||
let file = getTestDataDirectory();
|
||||
filename.split('/').forEach((part) => file.append(part));
|
||||
let importOptions = {
|
||||
file
|
||||
file,
|
||||
parentItemID: options.parentID
|
||||
};
|
||||
Object.assign(importOptions, options);
|
||||
return Zotero.Attachments.importFromFile(importOptions);
|
||||
|
|
Loading…
Reference in a new issue