From 79695028c05e30b114c7933b805b191f5c3f97e0 Mon Sep 17 00:00:00 2001 From: RaNaN Date: Thu, 29 Dec 2011 00:44:20 +0100 Subject: closed #479 --- module/plugins/hoster/MegauploadCom.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'module/plugins/hoster') diff --git a/module/plugins/hoster/MegauploadCom.py b/module/plugins/hoster/MegauploadCom.py index 100553ebf..6b5d10729 100644 --- a/module/plugins/hoster/MegauploadCom.py +++ b/module/plugins/hoster/MegauploadCom.py @@ -65,7 +65,7 @@ class MegauploadCom(Hoster): __name__ = "MegauploadCom" __type__ = "hoster" __pattern__ = r"http://[\w\.]*?(megaupload)\.com/.*?(\?|&)d=(?P[0-9A-Za-z]+)" - __version__ = "0.28" + __version__ = "0.3" __description__ = """Megaupload.com Download Hoster""" __author_name__ = ("spoob") __author_mail__ = ("spoob@pyload.org") @@ -74,6 +74,7 @@ class MegauploadCom(Hoster): API_STATUS_MAPPING = {"0": statusMap['online'], "1": statusMap['offline'], "3": statusMap['temp. offline']} FILE_URL_PATTERN = r'' def init(self): self.html = [None, None] @@ -125,12 +126,12 @@ class MegauploadCom(Hoster): if e.args and e.args[0] == 33: # undirect download and resume , not a good idea page = self.load(pyfile.url) - self.download(re.search(r'href=\"(http://[^\"]*?)\" class=\"down_ad_butt1\">', page).group(1)) + self.download(re.search(self.PREMIUM_URL_PATTERN, page).group(1)) return else: raise - check = self.checkDownload({"dllink": re.compile(r'href=\"(http://[^\"]*?)\" class=\"down_ad_butt1\">')}) + check = self.checkDownload({"dllink": re.compile(self.PREMIUM_URL_PATTERN)}) if check == "dllink": self.log.warning(_("You should enable direct Download in your Megaupload Account settings")) @@ -270,4 +271,4 @@ class MegauploadCom(Hoster): if re.search("The password you have entered is not correct", self.html[1]): self.fail(_("Wrong password for download link.")) - return True \ No newline at end of file + return True -- cgit v1.2.3