diff --git a/chrome/content/zotero/xpcom/http.js b/chrome/content/zotero/xpcom/http.js index 5214c06f61..db4f098bc6 100644 --- a/chrome/content/zotero/xpcom/http.js +++ b/chrome/content/zotero/xpcom/http.js @@ -671,8 +671,9 @@ Zotero.HTTP = new function() { ); var bytes = new Uint8Array(await req.response.arrayBuffer()); await IOUtils.write(path, bytes); + var byteLength = bytes.byteLength; - Zotero.debug(`Saved file to ${path} (${bytes} byte${bytes != 1 ? 's' : ''})`); + Zotero.debug(`Saved file to ${path} (${byteLength} byte${byteLength != 1 ? 's' : ''})`); return req; };