mirror of
https://github.com/JimmXinu/FanFicFare.git
synced 2026-01-28 11:13:02 +01:00
Fixed finding of chapter URLs
This commit is contained in:
parent
9ce6117688
commit
2cb139147a
1 changed files with 4 additions and 1 deletions
|
|
@ -192,7 +192,10 @@ class SpikeluverComAdapter(BaseSiteAdapter):
|
|||
self.story.setMetadata('dateUpdated', makeDate(value, self.DATETIME_FORMAT))
|
||||
|
||||
for p_tag in listbox_tag.findNextSiblings('p'):
|
||||
chapter_anchor = p_tag.find('a')
|
||||
chapter_anchor = p_tag.find('a', href=lambda href: href and href.startswith('viewstory.php?sid='))
|
||||
if not chapter_anchor:
|
||||
continue
|
||||
|
||||
title = chapter_anchor.string.strip()
|
||||
url = urlparse.urljoin(self.BASE_URL, chapter_anchor['href'])
|
||||
self.chapterUrls.append((title, url))
|
||||
|
|
|
|||
Loading…
Reference in a new issue