Merge pull request #772 from Gluejar/doab-nits

don't load chapters
pull/91/head
eshellman 2018-04-23 15:42:52 -04:00 committed by GitHub
commit 0cf8b19b5f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -421,6 +421,9 @@ def load_doab_oai(from_year=None, limit=100000):
for record in doab_client.listRecords(metadataPrefix='oai_dc', from_=from_): for record in doab_client.listRecords(metadataPrefix='oai_dc', from_=from_):
if not record[1]: if not record[1]:
continue continue
item_type = unlist(record[1].getMap().get('type', None))
if item_type != 'book':
continue
idents = record[1].getMap()['identifier'] idents = record[1].getMap()['identifier']
if idents: if idents:
for ident in idents: for ident in idents: