diff options
author | Stefano <l.stickell@yahoo.it> | 2013-07-23 20:22:42 +0200 |
---|---|---|
committer | Stefano <l.stickell@yahoo.it> | 2013-07-23 20:22:42 +0200 |
commit | f5535809bebc6cc343475704832c8fd8674d2d06 (patch) | |
tree | c59bc1e6d71c04f5545ea262056c0c5be1bd8910 /module/plugins/accounts/FourSharedCom.py | |
parent | Fixed PEP 8 violations in Hosters (diff) | |
download | pyload-f5535809bebc6cc343475704832c8fd8674d2d06.tar.xz |
Fixed PEP 8 violations in Accounts
Diffstat (limited to 'module/plugins/accounts/FourSharedCom.py')
-rw-r--r-- | module/plugins/accounts/FourSharedCom.py | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/module/plugins/accounts/FourSharedCom.py b/module/plugins/accounts/FourSharedCom.py index bd3820277..69a465671 100644 --- a/module/plugins/accounts/FourSharedCom.py +++ b/module/plugins/accounts/FourSharedCom.py @@ -20,6 +20,7 @@ from module.plugins.Account import Account from module.common.json_layer import json_loads + class FourSharedCom(Account): __name__ = "FourSharedCom" __version__ = "0.01" @@ -27,22 +28,22 @@ class FourSharedCom(Account): __description__ = """FourSharedCom account plugin""" __author_name__ = ("zoidberg") __author_mail__ = ("zoidberg@mujmail.cz") - - def loadAccountInfo(self, user, req): + + def loadAccountInfo(self, user, req): #fixme - return ({"validuntil": -1, "trafficleft": -1, "premium": False}) - + return {"validuntil": -1, "trafficleft": -1, "premium": False} + def login(self, user, data, req): req.cj.setCookie("www.4shared.com", "4langcookie", "en") response = req.load('http://www.4shared.com/login', - post = {"login": user, - "password": data['password'], - "remember": "false", - "doNotRedirect": "true"}) - self.logDebug(response) + post={"login": user, + "password": data['password'], + "remember": "false", + "doNotRedirect": "true"}) + self.logDebug(response) response = json_loads(response) - + if not "ok" in response or response['ok'] != True: if "rejectReason" in response and response['rejectReason'] != True: - self.logError(response['rejectReason']) - self.wrongPassword()
\ No newline at end of file + self.logError(response['rejectReason']) + self.wrongPassword() |