diff options
author | Walter Purcaro <vuolter@gmail.com> | 2015-01-03 21:21:12 +0100 |
---|---|---|
committer | Walter Purcaro <vuolter@gmail.com> | 2015-01-03 21:21:12 +0100 |
commit | 29b8cb656f7145e70b80bc9ed11d862a2223b3f4 (patch) | |
tree | c6b86fd0ed3689f2eebf7246f463d79a07e9f72d /module | |
parent | [MultiHook] Unload if related multihoster account is not available (diff) | |
parent | Update OverLoadMe.py (diff) | |
download | pyload-29b8cb656f7145e70b80bc9ed11d862a2223b3f4.tar.xz |
Merge pull request #1004 from marley2013/patch-5
[OverLoadMe] Https support in account plugin
Diffstat (limited to 'module')
-rw-r--r-- | module/plugins/accounts/OverLoadMe.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/module/plugins/accounts/OverLoadMe.py b/module/plugins/accounts/OverLoadMe.py index fb9732986..e06fc2023 100644 --- a/module/plugins/accounts/OverLoadMe.py +++ b/module/plugins/accounts/OverLoadMe.py @@ -7,7 +7,7 @@ from module.common.json_layer import json_loads class OverLoadMe(Account): __name__ = "OverLoadMe" __type__ = "account" - __version__ = "0.01" + __version__ = "0.02" __description__ = """Over-Load.me account plugin""" __license__ = "GPLv3" @@ -16,7 +16,8 @@ class OverLoadMe(Account): def loadAccountInfo(self, user, req): data = self.getAccountData(user) - html = req.load("https://api.over-load.me/account.php", get={"user": user, "auth": data['password']}).strip() + https = "https" if self.getConfig("https") else "http" + html = req.load(https + "://api.over-load.me/account.php", get={"user": user, "auth": data['password']}).strip() data = json_loads(html) # Check for premium @@ -28,7 +29,8 @@ class OverLoadMe(Account): def login(self, user, data, req): - jsondata = req.load("https://api.over-load.me/account.php", + https = "https" if self.getConfig("https") else "http" + jsondata = req.load(https + "://api.over-load.me/account.php", get={"user": user, "auth": data['password']}).strip() data = json_loads(jsondata) |