From d1308359025d838bde20398c4735011b4883fca1 Mon Sep 17 00:00:00 2001 From: Pete Matsyburka Date: Mon, 20 Nov 2023 00:04:20 +0200 Subject: [PATCH] skip annots on error --- lib/templates/build_annotations.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/templates/build_annotations.rb b/lib/templates/build_annotations.rb index 8d0113c88..54f584b4c 100644 --- a/lib/templates/build_annotations.rb +++ b/lib/templates/build_annotations.rb @@ -17,7 +17,9 @@ def call(data) build_external_link_hash(page, annot).merge('page' => index) end end - rescue PDF::Reader::MalformedPDFError, OpenSSL::Cipher::CipherError + rescue StandardError => e + Rollbar.error(e) if defined?(Rollbar) + [] end