summaryrefslogtreecommitdiffstats
path: root/module
diff options
context:
space:
mode:
authorGravatar Nitzo <nitzo2001@yahoo.com> 2016-06-01 21:30:16 +0200
committerGravatar Nitzo <nitzo2001@yahoo.com> 2016-06-01 21:30:16 +0200
commitd143c31e0bd134b806a341b3c88041ea2a4f88ee (patch)
treea18481617a2b2093c7fccfd014051c8efd587092 /module
parent[Account] Fix typo (diff)
downloadpyload-d143c31e0bd134b806a341b3c88041ea2a4f88ee.tar.xz
[NitroflareCom] Update
Diffstat (limited to 'module')
-rw-r--r--module/plugins/accounts/NitroflareCom.py13
1 files changed, 7 insertions, 6 deletions
diff --git a/module/plugins/accounts/NitroflareCom.py b/module/plugins/accounts/NitroflareCom.py
index 7ffcd172d..e6cfc1b34 100644
--- a/module/plugins/accounts/NitroflareCom.py
+++ b/module/plugins/accounts/NitroflareCom.py
@@ -11,7 +11,7 @@ from module.plugins.captcha.ReCaptcha import ReCaptcha
class NitroflareCom(Account):
__name__ = "NitroflareCom"
__type__ = "account"
- __version__ = "0.15"
+ __version__ = "0.16"
__status__ = "testing"
__description__ = """Nitroflare.com account plugin"""
@@ -73,12 +73,15 @@ class NitroflareCom(Account):
def signin(self, user, password, data):
login_url = "https://nitroflare.com/login"
+
+ self.data = self.load(login_url)
+ if "document.location.href='logout'" in self.data:
+ self.skip_login()
+
post_data = {'login' : "",
'email' : user,
'password': password}
- self.data = self.load(login_url)
-
# dummy pyfile
pyfile = PyFile(self.pyload.files, -1, login_url, login_url, 0, 0, "", self.classname, -1, -1)
pyfile.plugin = self
@@ -93,7 +96,7 @@ class NitroflareCom(Account):
token = re.search(self.TOKEN_PATTERN, self.data).group(1)
post_data['token'] = token
- self.data = self.load("https://nitroflare.com/login", post=post_data)
+ self.data = self.load(login_url, post=post_data)
if re.search(self.LOGIN_FAIL_PATTERN, self.data):
self.fail_login()
@@ -108,5 +111,3 @@ class NitroflareCom(Account):
def retry_captcha(self, attemps=10, wait=1, msg=_("Max captcha retries reached")):
self.captcha.invalid()
self.fail_login(msg="Invalid captcha")
-
-