diff options
author | spoob <spoob@gmx.de> | 2009-12-16 22:28:57 +0100 |
---|---|---|
committer | spoob <spoob@gmx.de> | 2009-12-16 22:28:57 +0100 |
commit | 9fd8d0c20d4495319b72bd2faa7275c75a7fcacc (patch) | |
tree | 2d1ac039749143801e8e41a0244874bbf2ffe4ef /module/plugins | |
parent | new images (diff) | |
download | pyload-9fd8d0c20d4495319b72bd2faa7275c75a7fcacc.tar.xz |
Fixed Relink.us, Uploaded.to Name Bug
Diffstat (limited to 'module/plugins')
-rw-r--r-- | module/plugins/RelinkUs.py | 9 | ||||
-rw-r--r-- | module/plugins/UploadedTo.py | 12 |
2 files changed, 7 insertions, 14 deletions
diff --git a/module/plugins/RelinkUs.py b/module/plugins/RelinkUs.py index 786733558..71b441116 100644 --- a/module/plugins/RelinkUs.py +++ b/module/plugins/RelinkUs.py @@ -4,7 +4,7 @@ import re import time -from Plugin import Plugin +from module.Plugin import Plugin class RelinkUs(Plugin): @@ -14,10 +14,10 @@ class RelinkUs(Plugin): props['name'] = "RelinkUs" props['type'] = "container" props['pattern'] = r"http://(www\.)?relink.us/(f|((view|go).php))" - props['version'] = "0.2" + props['version'] = "1" props['description'] = """Relink.us Container Plugin""" - props['author_name'] = ("Sleeper-") - props['author_mail'] = ("@nonymous") + props['author_name'] = ("Sleeper-", "spoob") + props['author_mail'] = ("@nonymous", "spoob@pyload.org") self.props = props self.parent = parent self.html = None @@ -55,7 +55,6 @@ class RelinkUs(Plugin): # Wait some secs for relink.us server... time.sleep(5) - print new_link temp_links.append(new_link) self.links = temp_links diff --git a/module/plugins/UploadedTo.py b/module/plugins/UploadedTo.py index 4bddbd6f1..bb623b4e6 100644 --- a/module/plugins/UploadedTo.py +++ b/module/plugins/UploadedTo.py @@ -21,7 +21,6 @@ class UploadedTo(Plugin): self.props = props self.parent = parent self.html = None - self.html_old = None #time() where loaded the HTML self.time_plus_wait = None #time() + wait in seconds self.api_data = None self.want_reconnect = False @@ -35,12 +34,11 @@ class UploadedTo(Plugin): def prepare(self, thread): pyfile = self.parent - + self.want_reconnect = False tries = 0 while not pyfile.status.url: - self.req.clear_cookies() self.download_html() @@ -84,7 +82,7 @@ class UploadedTo(Plugin): self.api_data["filename"] = lines[0] self.api_data["size"] = lines[1] # in kbytes self.api_data["checksum"] = lines[2] #sha1 - + def download_html(self): if self.config['premium']: self.config['username'], self.config['password'] @@ -107,7 +105,6 @@ class UploadedTo(Plugin): if self.config['premium']: self.start_dl = True return self.parent.url - try: file_url_pattern = r".*<form name=\"download_form\" method=\"post\" action=\"(.*)\">" return re.search(file_url_pattern, self.html).group(1) @@ -124,12 +121,9 @@ class UploadedTo(Plugin): return file_name return file_name + file_suffix.group(1) except: - self.parent.status.url = None return self.parent.url def file_exists(self): - """ returns True or False - """ if re.search(r"(File doesn't exist .*)", self.html) != None: return False else: @@ -153,4 +147,4 @@ class UploadedTo(Plugin): else: return (False, 1) else: - return (True, 5) + return (True, 5) |