From a40cf88920e94490d5c851fb273b8d2f48aef6fb Mon Sep 17 00:00:00 2001 From: mkaay Date: Fri, 10 Jun 2011 13:09:33 +0200 Subject: ernieb's hoster patches --- module/plugins/hoster/FreakshareCom.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'module/plugins/hoster/FreakshareCom.py') diff --git a/module/plugins/hoster/FreakshareCom.py b/module/plugins/hoster/FreakshareCom.py index 795cafadf..1c4e04dee 100644 --- a/module/plugins/hoster/FreakshareCom.py +++ b/module/plugins/hoster/FreakshareCom.py @@ -81,12 +81,15 @@ class FreakshareCom(Hoster): def get_waiting_time(self): if self.html is None: self.download_html() - + if "Der Traffic f\xc3\xbcr heute ist verbraucht!" in self.html or "Your Traffic is used up for today" in self.html: self.wantReconnect = True return 24*3600 - - timestring = re.search('\s*var\stime\s=\s(\d*?)\.\d*;', self.html).group(1) + + if re.search(r"This file does not exist!", self.html) is not None: + self.offline() + + timestring = re.search('\s*var\sdownloadWait\s=\s(\d*);', self.html).group(1) if timestring: sec = int(timestring) + 1 #add 1 sec as tenths of seconds are cut off else: -- cgit v1.2.3