From 7de29233e07ab918e5d22477b303fb8586023be1 Mon Sep 17 00:00:00 2001 From: Edward Betts Date: Fri, 8 Nov 2019 21:21:43 +0000 Subject: [PATCH] Bug fix --- depicts/museodelprado.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/depicts/museodelprado.py b/depicts/museodelprado.py index 76f170f..129127a 100644 --- a/depicts/museodelprado.py +++ b/depicts/museodelprado.py @@ -24,7 +24,7 @@ def parse_html(html): keywords = [] for h2 in root.findall('.//h2'): - if h2.text.strip() != 'Displayed objects': + if not h2.text or h2.text.strip() != 'Displayed objects': continue div = h2.getparent() for keyword_span in div.findall('.//span[@property]'):