mirror of
https://github.com/mikf/gallery-dl.git
synced 2024-11-22 10:42:34 +01:00
[nijie] change 'email'-parameter to 'username'
This commit is contained in:
parent
794fa22762
commit
d01b21c6c8
@ -35,7 +35,7 @@ class NijieUserExtractor(AsynchronousExtractor):
|
||||
|
||||
def items(self):
|
||||
self.session.cookies = self.login(
|
||||
config.interpolate(("extractor", self.category, "email")),
|
||||
config.interpolate(("extractor", self.category, "username")),
|
||||
config.interpolate(("extractor", self.category, "password"))
|
||||
)
|
||||
data = self.get_job_metadata()
|
||||
@ -70,9 +70,9 @@ class NijieUserExtractor(AsynchronousExtractor):
|
||||
})
|
||||
|
||||
@cache(maxage=30*24*60*60, keyarg=1)
|
||||
def login(self, email, password):
|
||||
def login(self, username, password):
|
||||
"""Login and obtain session cookie"""
|
||||
params = {"email": email, "password": password}
|
||||
params = {"email": username, "password": password}
|
||||
page = self.session.post("https://nijie.info/login_int.php", data=params).text
|
||||
if "//nijie.info/login.php" in page:
|
||||
raise exception.AuthenticationError()
|
||||
|
Loading…
Reference in New Issue
Block a user