fix findhost popcornstream e try except nella ricerca

This commit is contained in:
marco
2020-05-13 14:34:05 +02:00
parent a5b0ce0974
commit 886940f46d
3 changed files with 19 additions and 30 deletions
+3 -9
View File
@@ -12,16 +12,10 @@ list_servers = ['verystream', 'openload', 'wstream']
list_quality = ['1080p', 'HD', 'DVDRIP', 'SD', 'CAM']
def findhost():
permUrl = httptools.downloadpage('https://www.popcornstream.info', follow_redirects=False, only_headers=True).headers
if 'google' in permUrl['location']:
host = permUrl['location'].replace('https://www.google.it/search?q=site:', '')
if host[:4] != 'http':
host = 'https://'+permUrl['location'].replace('https://www.google.it/search?q=site:', '')
else:
host = permUrl['location']
return host
data = httptools.downloadpage('https://www.popcornstream-nuovo-indirizzo.online/').data
return support.scrapertools.find_single_match(data, '<a href="([^"]+)')
host = config.get_channel_url()
host = config.get_channel_url(findhost)
headers = [['Referer', host]]
@support.menu