fix ilgenio e vcrypt su kodi 19

This commit is contained in:
marco
2020-12-20 20:54:18 +01:00
parent 923beb5bba
commit 3ffb7498f4
5 changed files with 397 additions and 380 deletions
+4 -4
View File
@@ -25,10 +25,10 @@ BASE_URL_TRANSLATE = 'https://translate.google.com/translate?hl=it&sl=en&tl=it&u
def checker_url(html, url):
grep_regex = re.findall(r'href="|src="|value="|((?:http[s]://|ftp[s]://)+\.*([-a-zA-Z0-9\.]+)([-a-zA-Z0-9\.]){1,}([-a-zA-Z0-9_\.\#\@\:%_/\?\=\~\&\-\//\!\'\;\(\)\s\^\:blank:\:punct:\:xdigit:\:space:\$]+))', html) # noqa: E501
grep_regex = re.findall(r'(?:href="|src="|value=")([^"]+)', html) # noqa: E501
for url_result_regex in grep_regex:
if url in url_result_regex[0]:
return url_result_regex[0].replace('&', '&')
if url in url_result_regex:
return url_result_regex.replace('&', '&')
def process_request_proxy(url):
@@ -60,7 +60,7 @@ def process_request_proxy(url):
)
url_request_proxy = checker_url(
request_final.text, BASE_URL_PROXY + '/translate_c?depth=1')
request_final.text, 'translate.google')
logger.debug(url_request_proxy)