diff options
author | 2015-12-14 16:47:49 +0100 | |
---|---|---|
committer | 2015-12-27 21:22:11 +0100 | |
commit | 8fe2fa85605c091369c8e69b36d1cded2cd9bbe0 (patch) | |
tree | a0d5745b1168fe887568fc6af1004c19ce44f4b6 /module/plugins/hoster/Http.py | |
parent | [ExternalScripts] Update and fix (diff) | |
download | pyload-8fe2fa85605c091369c8e69b36d1cded2cd9bbe0.tar.xz |
Update hosters (1)
Diffstat (limited to 'module/plugins/hoster/Http.py')
-rw-r--r-- | module/plugins/hoster/Http.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/module/plugins/hoster/Http.py b/module/plugins/hoster/Http.py index 5740e498f..f324ee986 100644 --- a/module/plugins/hoster/Http.py +++ b/module/plugins/hoster/Http.py @@ -3,13 +3,13 @@ import re import urlparse -from module.plugins.internal.Hoster import Hoster, create_getInfo +from module.plugins.internal.Hoster import Hoster class Http(Hoster): __name__ = "Http" __type__ = "hoster" - __version__ = "0.04" + __version__ = "0.05" __status__ = "testing" __pattern__ = r'(?:jd|pys?)://.+' @@ -66,9 +66,12 @@ class Http(Hoster): def check_download(self): - errmsg = self.check_file({'Html error' : re.compile(r'\A(?:\s*<.+>)?((?:[\w\s]*(?:[Ee]rror|ERROR)\s*\:?)?\s*\d{3})(?:\Z|\s+)'), - 'Html file' : re.compile(r'\A\s*<!DOCTYPE html'), - 'Request error': re.compile(r'([Aa]n error occured while processing your request)')}) + errmsg = self.scan_download({ + 'Html error' : re.compile(r'\A(?:\s*<.+>)?((?:[\w\s]*(?:[Ee]rror|ERROR)\s*\:?)?\s*\d{3})(?:\Z|\s+)'), + 'Html file' : re.compile(r'\A\s*<!DOCTYPE html'), + 'Request error': re.compile(r'([Aa]n error occured while processing your request)') + }) + if not errmsg: return @@ -80,6 +83,3 @@ class Http(Hoster): self.log_warning(_("Check result: ") + errmsg, _("Waiting 1 minute and retry")) self.retry(3, 60, errmsg) - - -getInfo = create_getInfo(Http) |