1
0
mirror of https://github.com/laurent22/joplin.git synced 2024-12-24 10:27:10 +02:00

Desktop: Fixes #10056: Fixed error when processing certain PDF files for OCR

This commit is contained in:
Laurent Cozic 2024-04-27 08:45:52 +01:00
parent c5dfa4c055
commit be58fced93

View File

@ -771,7 +771,11 @@ function shimInit(options: ShimInitOptions = null) {
}; };
const loadPdf = async (path: string) => { const loadPdf = async (path: string) => {
const loadingTask = pdfJs.getDocument(path); const loadingTask = pdfJs.getDocument({
url: path,
// https://github.com/mozilla/pdf.js/issues/4244#issuecomment-1479534301
useSystemFonts: true,
});
return await loadingTask.promise; return await loadingTask.promise;
}; };