Fix AnimeUnity, HD4ME, ToonItalia

This commit is contained in:
Alhaziel01
2021-06-07 17:23:54 +02:00
parent 986d6e63ea
commit 1e7f7d9407
5 changed files with 26 additions and 17 deletions

View File

@@ -3,6 +3,7 @@
# Canale per AnimeUnity
# ------------------------------------------------------------
from lib.requests.sessions import session
import requests, json, copy, inspect
from core import support
from platformcode import autorenumber
@@ -115,8 +116,10 @@ def news(item):
support.info()
item.contentType = 'episode'
itemlist = []
import cloudscraper
session = cloudscraper.create_scraper()
fullJs = json.loads(support.match(item, headers=headers, patron=r'items-json="([^"]+)"').match.replace('"','"'))
fullJs = json.loads(support.match(session.get(item.url).text, headers=headers, patron=r'items-json="([^"]+)"', debug=True).match.replace('"','"'))
js = fullJs['data']
for it in js: