diff options
author | Walter Purcaro <vuolter@gmail.com> | 2014-12-18 16:02:29 +0100 |
---|---|---|
committer | Walter Purcaro <vuolter@gmail.com> | 2014-12-18 16:02:29 +0100 |
commit | fb65d5354c3cc80c3f48c3a2745b8dc01105edfd (patch) | |
tree | 822240f20e27f2d5edc3e10624fc622e7c26cdc6 /module/plugins/accounts/RealdebridCom.py | |
parent | [UploadedTo] Fix trafficleft recognition (diff) | |
download | pyload-fb65d5354c3cc80c3f48c3a2745b8dc01105edfd.tar.xz |
Update account plugins
Diffstat (limited to 'module/plugins/accounts/RealdebridCom.py')
-rw-r--r-- | module/plugins/accounts/RealdebridCom.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/module/plugins/accounts/RealdebridCom.py b/module/plugins/accounts/RealdebridCom.py index eeba34665..48b17df5f 100644 --- a/module/plugins/accounts/RealdebridCom.py +++ b/module/plugins/accounts/RealdebridCom.py @@ -8,7 +8,7 @@ from module.plugins.Account import Account class RealdebridCom(Account): __name__ = "RealdebridCom" __type__ = "account" - __version__ = "0.43" + __version__ = "0.44" __description__ = """Real-Debrid.com account plugin""" __license__ = "GPLv3" @@ -18,9 +18,9 @@ class RealdebridCom(Account): def loadAccountInfo(self, user, req): if self.pin_code: return {"premium": False} - page = req.load("https://real-debrid.com/api/account.php") - xml = dom.parseString(page) - account_info = {"validuntil": int(xml.getElementsByTagName("expiration")[0].childNodes[0].nodeValue), + html = req.load("https://real-debrid.com/api/account.php") + xml = dom.parseString(html) + account_info = {"validuntil": float(xml.getElementsByTagName("expiration")[0].childNodes[0].nodeValue), "trafficleft": -1} return account_info @@ -28,9 +28,9 @@ class RealdebridCom(Account): def login(self, user, data, req): self.pin_code = False - page = req.load("https://real-debrid.com/ajax/login.php", get={"user": user, "pass": data['password']}) - if "Your login informations are incorrect" in page: + html = req.load("https://real-debrid.com/ajax/login.php", get={"user": user, "pass": data['password']}) + if "Your login informations are incorrect" in html: self.wrongPassword() - elif "PIN Code required" in page: + elif "PIN Code required" in html: self.logWarning(_("PIN code required. Please login to https://real-debrid.com using the PIN or disable the double authentication in your control panel on https://real-debrid.com")) self.pin_code = True |