diff options
author | dec05eba <dec05eba@protonmail.com> | 2021-05-07 07:38:59 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2021-05-07 07:38:59 +0200 |
commit | 48e757baffbf75bc8a1e4171ad94c27d7356cafa (patch) | |
tree | 91cad8a939725bd3a52bf2bc726620d164d64a57 /plugins/readm.py | |
parent | 52c63554190b8421c6f2db72d490f50364a2e23d (diff) |
Migrate mangadex to new api, remove .in_progress files in tracked dir if they are old
Diffstat (limited to 'plugins/readm.py')
-rwxr-xr-x | plugins/readm.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/readm.py b/plugins/readm.py index 3101587..74ae43c 100755 --- a/plugins/readm.py +++ b/plugins/readm.py @@ -56,7 +56,7 @@ def list_chapters(url, chapter_list_input): for item in chapter_list_input: title = item.get("title") if title and len(title) > 0: - seen_titles.add(title.lower().replace(" ", "")) + seen_titles.add(title.lower().replace(" ", "").replace("/", "_")) seen_urls = set() for item in chapter_list_input: @@ -67,7 +67,7 @@ def list_chapters(url, chapter_list_input): tree = etree.HTML(response.text) chapters = [] for element in tree.xpath('//div[@class="episodes-list"]//a'): - element_text = element.text.strip() + element_text = element.text.strip().replace("/", "_") url = element.attrib.get("href").strip() url = "https://readm.org" + url if element_text.lower().replace(" ", "") in seen_titles or url in seen_urls: |