From 0806decd3f8ae63c6fccd25d4c0d3a3df7ab5c8c Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Wed, 22 May 2019 12:58:17 -0700 Subject: jalc empty publisher string --- python/fatcat_tools/importers/jalc.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'python/fatcat_tools') diff --git a/python/fatcat_tools/importers/jalc.py b/python/fatcat_tools/importers/jalc.py index fa3c108d..d560686f 100644 --- a/python/fatcat_tools/importers/jalc.py +++ b/python/fatcat_tools/importers/jalc.py @@ -207,7 +207,7 @@ class JalcImporter(EntityImporter): container_extra = dict() if record.publicationName: - pubs = [p.string.strip() for p in record.find_all("publicationName")] + pubs = [p.string.strip() for p in record.find_all("publicationName") if p.string] pubs = [clean(p) for p in pubs if p] assert(pubs) if len(pubs) > 1 and pubs[0] == pubs[1]: @@ -220,7 +220,7 @@ class JalcImporter(EntityImporter): container_extra['original_name'] = clean(pubs[1]) if record.publisher: - pubs = [p.string.strip() for p in record.find_all("publisher")] + pubs = [p.string.strip() for p in record.find_all("publisher") if p.string] pubs = [p for p in pubs if p] if len(pubs) > 1 and pubs[0] == pubs[1]: pubs = [pubs[0]] -- cgit v1.2.3