From ffbc2ed59181a649eef8a31f91b62546f27fd955 Mon Sep 17 00:00:00 2001 From: Florent VIOLLEAU Date: Thu, 9 Jul 2020 00:22:38 +0200 Subject: [PATCH] Fix #595: TypeError: 'NoneType' object is not subscriptable --- edx_dl/parsing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/edx_dl/parsing.py b/edx_dl/parsing.py index c381283..ff45a44 100644 --- a/edx_dl/parsing.py +++ b/edx_dl/parsing.py @@ -369,7 +369,7 @@ def extract_sections_from_html(self, page, BASE_URL): """ def _make_url(section_soup): # FIXME: Extract from here and test try: - return section_soup.a['href'] + return section_soup.ol except AttributeError: # Section might be empty and contain no links return None