aboutsummaryrefslogtreecommitdiffstats
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rw-r--r--python/sandcrawler/pdfextract.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/python/sandcrawler/pdfextract.py b/python/sandcrawler/pdfextract.py
index 3701172..5f9b898 100644
--- a/python/sandcrawler/pdfextract.py
+++ b/python/sandcrawler/pdfextract.py
@@ -78,7 +78,7 @@ class PdfExtractResult:
return PdfExtractResult(
sha1hex=record['sha1hex'],
status=record['status'],
- error_msg=record.get('metadata', {}).get('error_msg'),
+ error_msg=(record.get('metadata') or {}).get('error_msg'),
)
else:
pdf_extra = dict()