Skip to content

Commit

Permalink
Merge pull request #2141 from jere344/patch-5
Browse files Browse the repository at this point in the history
Added synopsis and fixed author
  • Loading branch information
dipu-bd authored Sep 26, 2023
2 parents b23983e + c484002 commit bb82158
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion sources/en/n/novelhall.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,18 @@ def read_novel_info(self):

author = soup.select("div.book-info div.total.booktag span.blue")[0]
author.select_one("p").extract()
self.novel_author = author.text.strip()
self.novel_author = author.text.replace("Author:", "").strip()
logger.info("Novel author: %s", self.novel_author)

self.novel_tags = [soup.select_one("div.book-info div.total.booktag a.red").text.strip()]
logger.info("Novel tags: %s", self.novel_tags)

synopsis = soup.select_one(".js-close-wrap")
if synopsis:
synopsis.select_one(".blue").extract()
self.novel_synopsis = self.cleaner.extract_contents(synopsis)
logger.info("Novel synopsis: %s", self.novel_synopsis)

for a in soup.select("div#morelist.book-catalog ul li a"):
chap_id = len(self.chapters) + 1
vol_id = len(self.chapters) // 100 + 1
Expand Down

0 comments on commit bb82158

Please sign in to comment.