diff options
author | Walter Purcaro <vuolter@users.noreply.github.com> | 2015-03-20 12:00:54 +0100 |
---|---|---|
committer | Walter Purcaro <vuolter@users.noreply.github.com> | 2015-03-20 12:00:54 +0100 |
commit | e4e743646a20d24077a8f1f95a0e5aa772771ff7 (patch) | |
tree | fb2bb8709096cce14417440bc16a9367090bd9d5 | |
parent | [DepositfilesCom] Fix https://github.com/pyload/pyload/issues/1268 (diff) | |
download | pyload-e4e743646a20d24077a8f1f95a0e5aa772771ff7.tar.xz |
[SimpleHoster] Fix checkErrors
-rw-r--r-- | module/plugins/internal/SimpleHoster.py | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/module/plugins/internal/SimpleHoster.py b/module/plugins/internal/SimpleHoster.py index 1b6b330b6..047d9edde 100644 --- a/module/plugins/internal/SimpleHoster.py +++ b/module/plugins/internal/SimpleHoster.py @@ -246,7 +246,7 @@ def secondsToMidnight(gmt=0): class SimpleHoster(Hoster): __name__ = "SimpleHoster" __type__ = "hoster" - __version__ = "1.27" + __version__ = "1.28" __pattern__ = r'^unmatchable$' __config__ = [("use_premium", "bool", "Use premium account if available", True)] @@ -522,7 +522,7 @@ class SimpleHoster(Hoster): 'Html error': re.compile(r'\A(?:\s*<.+>)?((?:[\w\s]*(?:[Ee]rror|ERROR)\s*\:?)?\s*\d{3})(?:\Z|\s+)')}) if not errmsg: - for r, p in [('Html file' , re.compile(r'\A\s*<!DOCTYPE html') ), + for r, p in [('Html file' , re.compile(r'\A\s*<!DOCTYPE html') ), ('Request error', re.compile(r'([Aa]n error occured while processing your request)'))]: if r not in rules: rules[r] = p @@ -567,12 +567,15 @@ class SimpleHoster(Hoster): self.info['error'] = errmsg - if "hour" in errmsg: - self.wait(secondsToMidnight(gmt=2), True) + if "min" in errmsg: + self.wait(1 * 60) - elif re.search("da(il)?y|today", errmsg): + elif "hour" in errmsg: self.wait(1 * 60 * 60, True) + elif re.search("da(il)?y|today", errmsg): + self.wait(secondsToMidnight(gmt=2), True) + else: self.error(errmsg) |