diff options
author | Bryan Newbold <bnewbold@robocracy.org> | 2019-05-30 16:56:36 -0700 |
---|---|---|
committer | Bryan Newbold <bnewbold@robocracy.org> | 2019-05-30 16:56:36 -0700 |
commit | 5c028c7098b39a031f51a662f9fb064a84c52f62 (patch) | |
tree | ad4edfe1296c76a3fbf02972f8cba9b7e7d7da13 /python | |
parent | 4915c764c9477fb81a0e4bcbac90110e181fe30f (diff) | |
download | fatcat-5c028c7098b39a031f51a662f9fb064a84c52f62.tar.gz fatcat-5c028c7098b39a031f51a662f9fb064a84c52f62.zip |
JALC: handle empty publisher string
Diffstat (limited to 'python')
-rw-r--r-- | python/fatcat_tools/importers/jalc.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/python/fatcat_tools/importers/jalc.py b/python/fatcat_tools/importers/jalc.py index 847a68e2..c1c13bb7 100644 --- a/python/fatcat_tools/importers/jalc.py +++ b/python/fatcat_tools/importers/jalc.py @@ -258,9 +258,10 @@ class JalcImporter(EntityImporter): if len(pubs) > 1 and is_cjk(pubs[0]): # ordering is not reliable pubs = [pubs[1], pubs[0]] - publisher = clean(pubs[0]) - if len(pubs) > 1: - container_extra['publisher_aliases'] = pubs[1:] + if pubs: + publisher = clean(pubs[0]) + if len(pubs) > 1: + container_extra['publisher_aliases'] = pubs[1:] if (container_id is None and self.create_containers and (issnl is not None) and container_name): |