Skip to content

Commit

Permalink
Merge pull request #2145 from jere344/patch-1
Browse files Browse the repository at this point in the history
fix author
  • Loading branch information
dipu-bd authored Sep 26, 2023
2 parents bb82158 + 916e08b commit 3401532
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions sources/en/l/lightnovelreader.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,13 +88,10 @@ def read_novel_info(self):
self.novel_tags = [tag.text.strip() for tag in tags if isinstance(tag, Tag)]
logger.info("Novel genre: %s", self.novel_tags)

for tag in soup.select(".container dl.text-xs"):
dt = tag.select_one("dt")
dd = tag.select_one("dd")
if not (isinstance(dt, Tag) and isinstance(dd, Tag)):
continue
if dt.text.strip() == "Author(s):":
self.novel_author = dd.text.strip()
self.novel_author = ', '.join([
a.text.strip()
for a in soup.select('.container .novels-detail-right-in-right a[href*="/author/"]')
])
logger.info("Novel author: %s", self.novel_author)

# possible_novel_id = soup.select_one('.js-load-chapters')
Expand Down

0 comments on commit 3401532

Please sign in to comment.