Skip to content

Commit 02e98a0

Browse files
committed
skip empty dates
1 parent 343eb8c commit 02e98a0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

database/scrape_common.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,9 @@ def get_trle_class(soup):
234234
def get_trle_release(soup):
235235
"""Extract the release date."""
236236
raw_date = soup.find('td', string='release date:').find_next('td').get_text(strip=True) or ""
237-
return convert_to_iso(raw_date)
237+
if raw_date:
238+
return convert_to_iso(raw_date)
239+
return raw_date
238240

239241

240242
def get_trle_difficulty(soup):

0 commit comments

Comments
 (0)