Fix MangaDex endOfLife check

This commit is contained in:
Techwolf 2021-01-21 00:56:18 -08:00 committed by Tobias Gruetzmacher
parent 13c612c26e
commit 0fc196eb3e

View file

@ -25,7 +25,9 @@ class MangaDex(_ParserScraper):
mangaData = manga.json()
# Determine if manga is complete and/or adult
if mangaData['manga']['last_chapter'] != '0':
self.endOfLife = True
for ch in mangaData['chapter']:
if mangaData['chapter'][ch]['chapter'] == mangaData['manga']['last_chapter']:
self.endOfLife = True
if mangaData['manga']['hentai'] != '0':
self.adult = True
# Prepare chapter list