Skip to content

Commit

Permalink
Merge pull request #18587 from Snuffleupagus/PDFViewer-check-AbortSig…
Browse files Browse the repository at this point in the history
…nal-any

Check that `AbortSignal.any()` is supported in `PDFViewer` too (PR 18586 follow-up)
  • Loading branch information
timvandermeij committed Aug 9, 2024
2 parents b7198d3 + da9cfe7 commit daabc7a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion web/pdf_viewer.js
Original file line number Diff line number Diff line change
Expand Up @@ -880,7 +880,11 @@ class PDFViewer {
viewer.before(element);
}

if (annotationEditorMode !== AnnotationEditorType.DISABLE) {
if (
((typeof PDFJSDev !== "undefined" && PDFJSDev.test("MOZCENTRAL")) ||
typeof AbortSignal.any === "function") &&
annotationEditorMode !== AnnotationEditorType.DISABLE
) {
const mode = annotationEditorMode;

if (pdfDocument.isPureXfa) {
Expand Down

0 comments on commit daabc7a

Please sign in to comment.