summaryrefslogtreecommitdiffstats
path: root/module/plugins/accounts/RapidshareCom.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-07-14 16:10:01 +0200
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-07-15 16:26:07 +0200
commit7b8c458cca7d21a029620f98e453f746fce69cd1 (patch)
tree9e97b0003a00ff8ac9ee6b777d94bb998c911d05 /module/plugins/accounts/RapidshareCom.py
parentFix code indentation, some bad whitespaces and missing authors + use 'not' in... (diff)
downloadpyload-7b8c458cca7d21a029620f98e453f746fce69cd1.tar.xz
Prefer single quote for dict key name
Diffstat (limited to 'module/plugins/accounts/RapidshareCom.py')
-rw-r--r--module/plugins/accounts/RapidshareCom.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/module/plugins/accounts/RapidshareCom.py b/module/plugins/accounts/RapidshareCom.py
index 0676a7d5b..d537a2f23 100644
--- a/module/plugins/accounts/RapidshareCom.py
+++ b/module/plugins/accounts/RapidshareCom.py
@@ -30,7 +30,7 @@ class RapidshareCom(Account):
data = self.getAccountData(user)
api_url_base = "http://api.rapidshare.com/cgi-bin/rsapi.cgi"
api_param_prem = {"sub": "getaccountdetails", "type": "prem", "login": user,
- "password": data["password"], "withcookie": 1}
+ "password": data['password'], "withcookie": 1}
src = req.load(api_url_base, cookies=False, get=api_param_prem)
if src.startswith("ERROR"):
raise Exception(src)
@@ -42,7 +42,7 @@ class RapidshareCom(Account):
k, v = t.split("=")
info[k] = v
- validuntil = int(info["billeduntil"])
+ validuntil = int(info['billeduntil'])
premium = True if validuntil else False
tmp = {"premium": premium, "validuntil": validuntil, "trafficleft": -1, "maxtraffic": -1}
@@ -52,7 +52,7 @@ class RapidshareCom(Account):
def login(self, user, data, req):
api_url_base = "http://api.rapidshare.com/cgi-bin/rsapi.cgi"
api_param_prem = {"sub": "getaccountdetails", "type": "prem", "login": user,
- "password": data["password"], "withcookie": 1}
+ "password": data['password'], "withcookie": 1}
src = req.load(api_url_base, cookies=False, get=api_param_prem)
if src.startswith("ERROR"):
raise Exception(src + "### Note you have to use your account number for login, instead of name.")
@@ -64,4 +64,4 @@ class RapidshareCom(Account):
k, v = t.split("=")
info[k] = v
cj = self.getAccountCookies(user)
- cj.setCookie("rapidshare.com", "enc", info["cookie"])
+ cj.setCookie("rapidshare.com", "enc", info['cookie'])