mirror of
https://github.com/kemayo/leech
synced 2025-12-06 16:33:16 +01:00
Xenforo: clean out title prefixes
This commit is contained in:
parent
c8f5b3f8d8
commit
b1b51bdc8f
1 changed files with 5 additions and 1 deletions
|
|
@ -65,8 +65,12 @@ class XenForo(Site):
|
||||||
|
|
||||||
base = soup.head.base.get('href')
|
base = soup.head.base.get('href')
|
||||||
|
|
||||||
|
title = soup.select('div.titleBar > h1')[0]
|
||||||
|
# clean out informational bits from the title
|
||||||
|
for tag in title.find_all(class_='prefix'):
|
||||||
|
tag.decompose()
|
||||||
story = Section(
|
story = Section(
|
||||||
title=soup.select('div.titleBar > h1')[0].get_text(),
|
title=title.get_text().strip(),
|
||||||
author=soup.find('p', id='pageDescription').find('a', class_='username').get_text(),
|
author=soup.find('p', id='pageDescription').find('a', class_='username').get_text(),
|
||||||
url=url
|
url=url
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue