diff --git a/src/display/optional_content_config.js b/src/display/optional_content_config.js index b50379efb..4f70893a4 100644 --- a/src/display/optional_content_config.js +++ b/src/display/optional_content_config.js @@ -95,6 +95,9 @@ class OptionalContentConfig { } isVisible(group) { + if (this._groups.size === 0) { + return true; + } if (!group) { warn("Optional content group not defined."); return true; diff --git a/test/pdfs/issue13971.pdf.link b/test/pdfs/issue13971.pdf.link new file mode 100644 index 000000000..de1eea548 --- /dev/null +++ b/test/pdfs/issue13971.pdf.link @@ -0,0 +1 @@ +https://github.com/mozilla/pdf.js/files/7109095/PDFBOX-5275-p5.pdf diff --git a/test/test_manifest.json b/test/test_manifest.json index 1cf730d01..ecc087cc6 100644 --- a/test/test_manifest.json +++ b/test/test_manifest.json @@ -3728,6 +3728,13 @@ "link": true, "type": "eq" }, + { "id": "issue13971", + "file": "pdfs/issue13971.pdf", + "md5": "50fbf6b9f26ea0e4427f33bae62a4d77", + "rounds": 1, + "link": true, + "type": "eq" + }, { "id": "issue1655", "file": "pdfs/issue1655r.pdf", "md5": "569f48449ba57c15c4f9ade151a651c5",