summaryrefslogtreecommitdiffstats
path: root/module/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'module/plugins')
-rw-r--r--module/plugins/hoster/RapidgatorNet.py16
1 files changed, 9 insertions, 7 deletions
diff --git a/module/plugins/hoster/RapidgatorNet.py b/module/plugins/hoster/RapidgatorNet.py
index b45543435..61141416a 100644
--- a/module/plugins/hoster/RapidgatorNet.py
+++ b/module/plugins/hoster/RapidgatorNet.py
@@ -14,7 +14,7 @@ from module.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo
class RapidgatorNet(SimpleHoster):
__name__ = "RapidgatorNet"
__type__ = "hoster"
- __version__ = "0.24"
+ __version__ = "0.25"
__pattern__ = r'http://(?:www\.)?(rapidgator\.net|rg\.to)/file/\w+'
@@ -44,18 +44,17 @@ class RapidgatorNet(SimpleHoster):
def setup(self):
- self.resumeDownload = self.multiDL = self.premium
- self.sid = None
- self.chunkLimit = 1
-
-
- def prepare(self):
if self.account:
self.sid = self.account.getAccountData(self.user).get('SID', None)
+ else:
+ self.sid = None
if self.sid:
self.premium = True
+ self.resumeDownload = self.multiDL = self.premium
+ self.chunkLimit = 1
+
def api_response(self, cmd):
try:
@@ -66,6 +65,7 @@ class RapidgatorNet(SimpleHoster):
json = json_loads(json)
status = json['response_status']
msg = json['response_details']
+
except BadHeader, e:
self.logError("API: %s" % cmd, str(e), "SID: %s" % self.sid)
status = e.code
@@ -73,9 +73,11 @@ class RapidgatorNet(SimpleHoster):
if status == 200:
return json['response']
+
elif status == 423:
self.account.empty(self.user)
self.retry()
+
else:
self.account.relogin(self.user)
self.retry(wait_time=60)