Fix Supervideo e Gounlimited

This commit is contained in:
Alhaziel01
2020-09-14 09:14:37 +02:00
parent 433d33f545
commit fea9d2f3b1
2 changed files with 4 additions and 5 deletions

View File

@@ -23,18 +23,18 @@ def get_video_url(page_url, premium=False, user="", password="", video_password=
logger.log("url=" + page_url)
video_urls = []
global data
# data = httptools.downloadpage(page_url, use_requests=True, verify=False).data
data = re.sub(r'"|\n|\r|\t|&nbsp;|<br>|\s{2,}', "", data)
logger.log('GOUN DATA= '+data)
# logger.log('GOUN DATA= '+data)
packed_data = scrapertools.find_single_match(data, "javascript'>(eval.*?)</script>")
unpacked = jsunpack.unpack(packed_data)
logger.log('GOUN DATA= '+unpacked)
# logger.log('GOUN DATA= '+unpacked)
patron = r"sources..([^\]]+)"
matches = re.compile(patron, re.DOTALL).findall(unpacked)
if not matches:
patron= r'src:([^,]+),'
matches = re.compile(patron, re.DOTALL).findall(unpacked)
for url in matches:
if url.startswith('//'): url= 'http:' + url
url += "|Referer=%s" %page_url
video_urls.append(['mp4 [Go Unlimited]', url])
return video_urls

View File

@@ -12,7 +12,7 @@ def test_video_exists(page_url):
logger.log("(page_url='%s')" % page_url)
global data
data = httptools.downloadpage(page_url, cookies=False).data
if 'File Not Found' in data:
if 'File is no longer available as it expired or has been deleted' in data:
return False, config.get_localized_string(70449) % "SuperVideo"
return True, ""
@@ -43,7 +43,6 @@ def get_video_url(page_url, premium=False, user="", password="", video_password=
video_urls.append(['.' + source['file'].split('.')[-1] + ' [' + quality + '] [SuperVideo]', source['file']])
else:
logger.log('ELSE!')
matches = scrapertools.find_multiple_matches(data, r'src:\s*"([^"]+)",\s*type:\s*"[^"]+"(?:\s*, res:\s(\d+))?')
for url, quality in matches:
if url.split('.')[-1] != 'm3u8':