mirror of
https://github.com/minetest/contentdb.git
synced 2024-12-23 06:22:24 +01:00
Fix crash in phpbbparser
This commit is contained in:
parent
20bf16abbf
commit
852e6ab5a0
@ -138,7 +138,11 @@ def parseForumListPage(id, page, out, extra=None):
|
|||||||
left = topic.find(class_="topic-poster")
|
left = topic.find(class_="topic-poster")
|
||||||
date = left.find("time").get_text()
|
date = left.find("time").get_text()
|
||||||
date = datetime.strptime(date, "%a %b %d, %Y %H:%M")
|
date = datetime.strptime(date, "%a %b %d, %Y %H:%M")
|
||||||
author = left.find_all("a")[-1].get_text().strip()
|
links = left.find_all("a")
|
||||||
|
if len(links) == 0:
|
||||||
|
continue
|
||||||
|
|
||||||
|
author = links[-1].get_text().strip()
|
||||||
|
|
||||||
# Get counts
|
# Get counts
|
||||||
posts = topic.find(class_="posts").find(text=True)
|
posts = topic.find(class_="posts").find(text=True)
|
||||||
|
Loading…
Reference in New Issue
Block a user