From 1d6c9adc791b62e3b236d118b55c34fc6b6e38ec Mon Sep 17 00:00:00 2001 From: zoidberg10 Date: Sun, 22 Apr 2012 00:41:13 +0200 Subject: fix uloz.to & bitshare.com premium --- module/plugins/hoster/BitshareCom.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'module/plugins/hoster/BitshareCom.py') diff --git a/module/plugins/hoster/BitshareCom.py b/module/plugins/hoster/BitshareCom.py index 1c7d79510..ba90f3ddc 100644 --- a/module/plugins/hoster/BitshareCom.py +++ b/module/plugins/hoster/BitshareCom.py @@ -46,7 +46,7 @@ class BitshareCom(Hoster): __name__ = "BitshareCom" __type__ = "hoster" __pattern__ = r"http://(www\.)?bitshare\.com/(files/(?P[a-zA-Z0-9]+)(/(?P.*?)\.html)?|\?f=(?P[a-zA-Z0-9]+))" - __version__ = "0.42" + __version__ = "0.43" __description__ = """Bitshare.Com File Download Hoster""" __author_name__ = ("paulking", "fragonib") __author_mail__ = (None, "fragonib[AT]yahoo[DOT]es") @@ -58,10 +58,12 @@ class BitshareCom(Hoster): CAPTCHA_KEY_PATTERN = r"http://api\.recaptcha\.net/challenge\?k=(.*?) " def setup(self): - self.multiDL = False + self.multiDL = self.premium self.chunkLimit = 1 def process(self, pyfile): + if self.premium: + self.account.relogin(self.user) self.pyfile = pyfile @@ -142,10 +144,12 @@ class BitshareCom(Hoster): url = response.split("#")[-1] return url - + def handleErrors(self, response, separator): self.logDebug("Checking response [%s]" % response) - if "ERROR" in response: + if "ERROR:Session timed out" in response: + self.retry() + elif "ERROR" in response: msg = response.split(separator)[-1] self.fail(msg) -- cgit v1.2.3