summaryrefslogtreecommitdiffstats
path: root/pyload/plugins/account/TurbobitNet.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyload/plugins/account/TurbobitNet.py')
-rw-r--r--pyload/plugins/account/TurbobitNet.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/pyload/plugins/account/TurbobitNet.py b/pyload/plugins/account/TurbobitNet.py
index 48ed17d73..cb8975158 100644
--- a/pyload/plugins/account/TurbobitNet.py
+++ b/pyload/plugins/account/TurbobitNet.py
@@ -7,18 +7,19 @@ from pyload.plugins.base.Account import Account
class TurbobitNet(Account):
- __name__ = "TurbobitNet"
- __type__ = "account"
+ __name__ = "TurbobitNet"
+ __type__ = "account"
__version__ = "0.01"
__description__ = """TurbobitNet account plugin"""
- __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
def loadAccountInfo(self, user, req):
html = req.load("http://turbobit.net")
- m = re.search(r'<u>Turbo Access</u> to ([0-9.]+)', html)
+ m = re.search(r'<u>Turbo Access</u> to ([\d.]+)', html)
if m:
premium = True
validuntil = mktime(strptime(m.group(1), "%d.%m.%Y"))
@@ -28,8 +29,9 @@ class TurbobitNet(Account):
return {"premium": premium, "trafficleft": -1, "validuntil": validuntil}
+
def login(self, user, data, req):
- req.cj.setCookie("turbobit.net", "user_lang", "en")
+ req.cj.setCookie(".turbobit.net", "user_lang", "en")
html = req.load("http://turbobit.net/user/login", post={
"user[login]": user,