summaryrefslogtreecommitdiffstats
path: root/module/plugins/hoster/RapiduNet.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-07-07 01:23:55 +0200
committerGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-07-07 01:23:55 +0200
commitb1759bc440cd6013837697eb8de540914f693ffd (patch)
treed170caf63d7f65e44d23ea2d91a65759a1665928 /module/plugins/hoster/RapiduNet.py
parent[Plugin] Fix decoding in load method (diff)
downloadpyload-b1759bc440cd6013837697eb8de540914f693ffd.tar.xz
No camelCase style anymore
Diffstat (limited to 'module/plugins/hoster/RapiduNet.py')
-rw-r--r--module/plugins/hoster/RapiduNet.py18
1 files changed, 9 insertions, 9 deletions
diff --git a/module/plugins/hoster/RapiduNet.py b/module/plugins/hoster/RapiduNet.py
index f2f1abfb7..30e453b93 100644
--- a/module/plugins/hoster/RapiduNet.py
+++ b/module/plugins/hoster/RapiduNet.py
@@ -12,7 +12,7 @@ from module.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo
class RapiduNet(SimpleHoster):
__name__ = "RapiduNet"
__type__ = "hoster"
- __version__ = "0.09"
+ __version__ = "0.10"
__pattern__ = r'https?://(?:www\.)?rapidu\.net/(?P<ID>\d{10})'
__config__ = [("use_premium", "bool", "Use premium account if available", True)]
@@ -33,22 +33,22 @@ class RapiduNet(SimpleHoster):
def setup(self):
- self.resumeDownload = True
- self.multiDL = self.premium
+ self.resume_download = True
+ self.multi_dl = self.premium
- def handleFree(self, pyfile):
+ def handle_free(self, pyfile):
self.req.http.lastURL = pyfile.url
self.req.http.c.setopt(pycurl.HTTPHEADER, ["X-Requested-With: XMLHttpRequest"])
- jsvars = self.getJsonResponse("https://rapidu.net/ajax.php",
+ jsvars = self.get_json_response("https://rapidu.net/ajax.php",
get={'a': "getLoadTimeToDownload"},
post={'_go': ""})
if str(jsvars['timeToDownload']) is "stop":
t = (24 * 60 * 60) - (int(time.time()) % (24 * 60 * 60)) + time.altzone
- self.logInfo("You've reach your daily download transfer")
+ self.log_info("You've reach your daily download transfer")
self.retry(10, 10 if t < 1 else None, _("Try tomorrow again")) #@NOTE: check t in case of not synchronised clock
@@ -58,7 +58,7 @@ class RapiduNet(SimpleHoster):
recaptcha = ReCaptcha(self)
response, challenge = recaptcha.challenge(self.RECAPTCHA_KEY)
- jsvars = self.getJsonResponse("https://rapidu.net/ajax.php",
+ jsvars = self.get_json_response("https://rapidu.net/ajax.php",
get={'a': "getCheckCaptcha"},
post={'_go' : "",
'captcha1': challenge,
@@ -69,12 +69,12 @@ class RapiduNet(SimpleHoster):
self.link = jsvars['url']
- def getJsonResponse(self, *args, **kwargs):
+ def get_json_response(self, *args, **kwargs):
res = self.load(*args, **kwargs)
if not res.startswith('{'):
self.retry()
- self.logDebug(res)
+ self.log_debug(res)
return json_loads(res)