findhost in channels.json

This commit is contained in:
marco
2020-10-09 20:15:04 +02:00
parent 454ef459f5
commit 3d39fbf4fa
20 changed files with 102 additions and 108 deletions

View File

@@ -11,8 +11,8 @@ from lib import unshortenit
from platformcode import logger, config
def findhost():
host = httptools.downloadpage('https://cb01.uno/', follow_redirect=True).url
def findhost(url):
host = httptools.downloadpage(url, follow_redirect=True).url
if host == 'https://cb01.uno/':
host = support.match(host, patron=r'<a href="([^"]+)', debug=True).match
return host