From 7b8c458cca7d21a029620f98e453f746fce69cd1 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Mon, 14 Jul 2014 16:10:01 +0200 Subject: Prefer single quote for dict key name --- module/plugins/accounts/UnrestrictLi.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/accounts/UnrestrictLi.py') diff --git a/module/plugins/accounts/UnrestrictLi.py b/module/plugins/accounts/UnrestrictLi.py index 2b647a49c..afc2f2a18 100644 --- a/module/plugins/accounts/UnrestrictLi.py +++ b/module/plugins/accounts/UnrestrictLi.py @@ -47,7 +47,7 @@ class UnrestrictLi(Account): self.logError("A Captcha is required. Go to http://unrestrict.li/sign_in and login, then retry") return - post_data = {"username": user, "password": data["password"], + post_data = {"username": user, "password": data['password'], "remember_me": "remember", "signin": "Sign in"} self.html = req.load("https://unrestrict.li/sign_in", post=post_data) -- cgit v1.2.3 From 8e47b0de30a25d0fd5dfb518bfe4e1e7beff93fd Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Tue, 15 Jul 2014 16:27:44 +0200 Subject: Key attributes cleanup for account, container and crypter plugins --- module/plugins/accounts/UnrestrictLi.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'module/plugins/accounts/UnrestrictLi.py') diff --git a/module/plugins/accounts/UnrestrictLi.py b/module/plugins/accounts/UnrestrictLi.py index afc2f2a18..ac2d2d82a 100644 --- a/module/plugins/accounts/UnrestrictLi.py +++ b/module/plugins/accounts/UnrestrictLi.py @@ -22,10 +22,12 @@ class UnrestrictLi(Account): __name__ = "UnrestrictLi" __version__ = "0.03" __type__ = "account" + __description__ = """Unrestrict.li account plugin""" __author_name__ = "stickell" __author_mail__ = "l.stickell@yahoo.it" + def loadAccountInfo(self, user, req): json_data = req.load('http://unrestrict.li/api/jdownloader/user.php?format=json') self.logDebug("JSON data: " + json_data) -- cgit v1.2.3 From 9762ac2fe94e3c6709fc46b6e9bde99e10cb3681 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sun, 20 Jul 2014 02:25:53 +0200 Subject: [account] self.html -> html (where was possible) --- module/plugins/accounts/UnrestrictLi.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'module/plugins/accounts/UnrestrictLi.py') diff --git a/module/plugins/accounts/UnrestrictLi.py b/module/plugins/accounts/UnrestrictLi.py index ac2d2d82a..94452b966 100644 --- a/module/plugins/accounts/UnrestrictLi.py +++ b/module/plugins/accounts/UnrestrictLi.py @@ -51,7 +51,7 @@ class UnrestrictLi(Account): post_data = {"username": user, "password": data['password'], "remember_me": "remember", "signin": "Sign in"} - self.html = req.load("https://unrestrict.li/sign_in", post=post_data) + html = req.load("https://unrestrict.li/sign_in", post=post_data) - if 'sign_out' not in self.html: + if 'sign_out' not in html: self.wrongPassword() -- cgit v1.2.3 From ba916633f2bedb04c7358000b91aed69f52e8e43 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Fri, 1 Aug 2014 19:35:59 +0200 Subject: Remove trailing whitespaces + remove license headers + import urllib methods directly + sort and fix key attributes + use save_join instead join + sort some import declarations + other minor code cosmetics --- module/plugins/accounts/UnrestrictLi.py | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) (limited to 'module/plugins/accounts/UnrestrictLi.py') diff --git a/module/plugins/accounts/UnrestrictLi.py b/module/plugins/accounts/UnrestrictLi.py index 94452b966..a65f19c5b 100644 --- a/module/plugins/accounts/UnrestrictLi.py +++ b/module/plugins/accounts/UnrestrictLi.py @@ -1,18 +1,4 @@ # -*- coding: utf-8 -*- -############################################################################ -# This program is free software: you can redistribute it and/or modify # -# it under the terms of the GNU Affero General Public License as # -# published by the Free Software Foundation, either version 3 of the # -# License, or (at your option) any later version. # -# # -# This program is distributed in the hope that it will be useful, # -# but WITHOUT ANY WARRANTY; without even the implied warranty of # -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # -# GNU Affero General Public License for more details. # -# # -# You should have received a copy of the GNU Affero General Public License # -# along with this program. If not, see . # -############################################################################ from module.plugins.Account import Account from module.common.json_layer import json_loads @@ -20,8 +6,8 @@ from module.common.json_layer import json_loads class UnrestrictLi(Account): __name__ = "UnrestrictLi" - __version__ = "0.03" __type__ = "account" + __version__ = "0.03" __description__ = """Unrestrict.li account plugin""" __author_name__ = "stickell" -- cgit v1.2.3