Skip to content

Commit

Permalink
Version 0.8.2
Browse files Browse the repository at this point in the history
Fixed ad code from novelplanet
  • Loading branch information
dr-nyt committed Sep 21, 2019
1 parent 9eb0474 commit 3368b9a
Show file tree
Hide file tree
Showing 7 changed files with 6 additions and 1 deletion.
File renamed without changes.
2 changes: 1 addition & 1 deletion Version 0.8.1/main.py → Version 0.8.2/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from novelplanet import NovelPlanetPanel

# Version number
version = "0.8.1"
version = "0.8.2"

# file dialog, used in the selection of book covers
wildcard = "Image file (*.png)" \
Expand Down
5 changes: 5 additions & 0 deletions Version 0.8.1/novelplanet.py → Version 0.8.2/novelplanet.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,11 @@ def run(self, link, cover, chapter_start, chapter_end, directory):
content = f"<h2>{current_chapter}</h2>"
# Get all the paragraphs from the chapter
paras = soup.find(id="divReadContent")

#Remove ads
for div in paras('div'):
div.decompose()

# Append all paragraph to content which will be added to the .xhtml
content += paras.prettify()
content += "<p> </p>"
Expand Down
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.

0 comments on commit 3368b9a

Please sign in to comment.