diff --git a/prsannots/pagetext.py b/prsannots/pagetext.py index 0f02753..f879218 100644 --- a/prsannots/pagetext.py +++ b/prsannots/pagetext.py @@ -56,7 +56,8 @@ def get_layouts(fd): parser = PDFParser(fd) doc = new_doc(parser) - doc.initialize() + if hasattr(doc, 'initialize'): + doc.initialize() laparams = LAParams() rsrcmgr = PDFResourceManager()