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/TurbobitNet.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/TurbobitNet.py')
-rw-r--r-- | module/plugins/accounts/TurbobitNet.py | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/module/plugins/accounts/TurbobitNet.py b/module/plugins/accounts/TurbobitNet.py index c4b819131..5d4471c30 100644 --- a/module/plugins/accounts/TurbobitNet.py +++ b/module/plugins/accounts/TurbobitNet.py @@ -17,10 +17,12 @@ @author: zoidberg """ -from module.plugins.Account import Account import re from time import mktime, strptime +from module.plugins.Account import Account + + class TurbobitNet(Account): __name__ = "TurbobitNet" __version__ = "0.01" @@ -28,12 +30,12 @@ class TurbobitNet(Account): __description__ = """TurbobitNet account plugin""" __author_name__ = ("zoidberg") __author_mail__ = ("zoidberg@mujmail.cz") - + #login_timeout = 60 - def loadAccountInfo(self, user, req): + def loadAccountInfo(self, user, req): html = req.load("http://turbobit.net") - + found = re.search(r'<u>Turbo Access</u> to ([0-9.]+)', html) if found: premium = True @@ -46,11 +48,11 @@ class TurbobitNet(Account): def login(self, user, data, req): req.cj.setCookie("turbobit.net", "user_lang", "en") - + html = req.load("http://turbobit.net/user/login", post={ "user[login]": user, "user[pass]": data["password"], "user[submit]": "Login"}) - + if not '<div class="menu-item user-name">' in html: - self.wrongPassword()
\ No newline at end of file + self.wrongPassword() |