diff options
author | TWD <tmp_m_box-xxx@yahoo.it> | 2015-06-16 12:05:29 +0200 |
---|---|---|
committer | TWD <tmp_m_box-xxx@yahoo.it> | 2015-06-16 12:05:29 +0200 |
commit | badcc797c41e9ee8b226ff803e8f22553a70bd10 (patch) | |
tree | bea4118b855dcf4de4e3e565616eb8f0e477b9fd /module | |
parent | Fix http://forum.pyload.org/viewtopic.php?f=10&t=4328 (diff) | |
download | pyload-badcc797c41e9ee8b226ff803e8f22553a70bd10.tar.xz |
Update NowDownloadSx.py
Diffstat (limited to 'module')
-rw-r--r-- | module/plugins/hoster/NowDownloadSx.py | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/module/plugins/hoster/NowDownloadSx.py b/module/plugins/hoster/NowDownloadSx.py index a1cf9baf7..b23382420 100644 --- a/module/plugins/hoster/NowDownloadSx.py +++ b/module/plugins/hoster/NowDownloadSx.py @@ -9,9 +9,9 @@ from module.utils import fixup class NowDownloadSx(SimpleHoster): __name__ = "NowDownloadSx" __type__ = "hoster" - __version__ = "0.09" + __version__ = "0.10" - __pattern__ = r'http://(?:www\.)?(nowdownload\.[a-zA-Z]{2,}/(dl/|download\.php.+?id=|mobile/(#/files/|.+?id=))|likeupload\.org/)\w+' + __pattern__ = r'http://(?:www\.)?(nowdownload\.([a-zA-Z]{2,})/(dl/|download\.php.+?id=|mobile/(#/files/|.+?id=))|likeupload\.org/)\w+' __config__ = [("use_premium", "bool", "Use premium account if available", True)] __description__ = """NowDownload.sx hoster plugin""" @@ -26,7 +26,7 @@ class NowDownloadSx(SimpleHoster): TOKEN_PATTERN = r'"(/api/token\.php\?token=\w+)"' CONTINUE_PATTERN = r'"(/dl2/\w+/\w+)"' WAIT_PATTERN = r'\.countdown\(\{until: \+(\d+),' - LINK_FREE_PATTERN = r'(http://s\d+\.coolcdn\.info/nowdownload/.+?)["\']' + LINK_FREE_PATTERN = r'(http://s\d+(\.coolcdn\.info|\.mighycdndelivery\.com)/nowdownload/.+?)["\']' NAME_REPLACEMENTS = [("&#?\w+;", fixup), (r'<.*?>', '')] @@ -49,7 +49,12 @@ class NowDownloadSx(SimpleHoster): else: wait = 60 - baseurl = "http://www.nowdownload.at" + foundbu = re.match(self.__pattern__, self.pyfile.url) + if foundbu: + baseurl = "http://www.nowdownload." + foundbu.group(2) + else: + baseurl = "http://www.nowdownload.ch" + self.html = self.load(baseurl + str(tokenlink.group(1))) self.wait(wait) |