From 056caae1244bb881431d7a197d0965355ab3cf8e Mon Sep 17 00:00:00 2001 From: Dan Scott Date: Tue, 7 Apr 2020 13:05:04 -0400 Subject: [PATCH] Recognize more DOIs for Springer books Signed-off-by: Dan Scott --- tools/ebooks/prep_ebook_records.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tools/ebooks/prep_ebook_records.py b/tools/ebooks/prep_ebook_records.py index 7786453e2f..339da4faa4 100755 --- a/tools/ebooks/prep_ebook_records.py +++ b/tools/ebooks/prep_ebook_records.py @@ -1324,10 +1324,15 @@ def get_subfields(field, data, platform): subs.extend([field.subfields[0], field.subfields[1]]) link_text = data["link_text"] + # We don't know what the 956 platform is if platform and field.tag != "956": link_text = "%s (%s)" % (data["link_text"], platform) - elif url.find("springer.com") > -1 or url.find("doi.org/10.1057/") > -1: + elif ( + url.find("springer.com") > -1 + or url.find("doi.org/10.1057/") > -1 + or url.find("doi.org/10.1007") > -1 + ): link_text = "%s (%s)" % (data["link_text"], "Springer") elif url.find("doi.org/10.1093/") > -1: link_text = "%s (%s)" % (data["link_text"], "Oxford Scholarship Online") -- 2.11.0