diff --git a/chrome/content/zotero/xpcom/pdfWorker/manager.js b/chrome/content/zotero/xpcom/pdfWorker/manager.js index bcd6785219..a99b3100d9 100644 --- a/chrome/content/zotero/xpcom/pdfWorker/manager.js +++ b/chrome/content/zotero/xpcom/pdfWorker/manager.js @@ -24,8 +24,8 @@ */ const WORKER_URL = 'chrome://zotero/content/xpcom/pdfWorker/worker.js'; -const CMAPS_URL = 'chrome://zotero/content/xpcom/pdfWorker/cmaps/'; -const STANDARD_FONTS_URL = 'chrome://zotero/content/xpcom/pdfWorker/standard_fonts/'; +const CMAPS_URL = 'resource://zotero/pdf-reader/cmaps/'; +const STANDARD_FONTS_URL = 'resource://zotero/pdf-reader/standard_fonts/'; const RENDERER_URL = 'resource://zotero/pdf-renderer/renderer.html'; class PDFWorker { diff --git a/pdf-reader b/pdf-reader index 590af78005..40d044fc8a 160000 --- a/pdf-reader +++ b/pdf-reader @@ -1 +1 @@ -Subproject commit 590af780053f198838c0f3b4afa3f197ef45453e +Subproject commit 40d044fc8aeb91d7855aa22b3025101e89c3a011 diff --git a/scripts/pdf-worker.js b/scripts/pdf-worker.js index 484fc4ad4c..9aef082022 100644 --- a/scripts/pdf-worker.js +++ b/scripts/pdf-worker.js @@ -35,8 +35,7 @@ async function getPDFWorker(signatures) { catch (e) { await exec('npm ci', { cwd: modulePath }); await exec('npm run build', { cwd: modulePath }); - // TODO: Don't copy 'cmaps' and 'standard_fonts' directories once pdf-reader is updated - await fs.copy(path.join(modulePath, 'build'), targetDir); + await fs.copy(path.join(modulePath, 'build', 'worker.js'), path.join(targetDir, 'worker.js')); } signatures['pdf-worker'] = { hash }; }