[fansly] emit debug logging message when using a 'token' (#4401)
This commit is contained in:
@@ -179,17 +179,18 @@ class FanslyAPI():
|
|||||||
|
|
||||||
def __init__(self, extractor):
|
def __init__(self, extractor):
|
||||||
self.extractor = extractor
|
self.extractor = extractor
|
||||||
|
|
||||||
token = extractor.config("token")
|
|
||||||
if not token:
|
|
||||||
self.extractor.log.warning("No 'token' provided")
|
|
||||||
|
|
||||||
self.headers = {
|
self.headers = {
|
||||||
"fansly-client-ts": None,
|
"fansly-client-ts": None,
|
||||||
"Origin" : extractor.root,
|
"Origin" : extractor.root,
|
||||||
"authorization" : token,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if token := extractor.config("token"):
|
||||||
|
self.headers["authorization"] = token
|
||||||
|
self.extractor.log.debug(
|
||||||
|
"Using authorization 'token' %.5s...", token)
|
||||||
|
else:
|
||||||
|
self.extractor.log.warning("No 'token' provided")
|
||||||
|
|
||||||
def account(self, username):
|
def account(self, username):
|
||||||
endpoint = "/v1/account"
|
endpoint = "/v1/account"
|
||||||
params = {"usernames": username}
|
params = {"usernames": username}
|
||||||
|
|||||||
@@ -6,5 +6,5 @@
|
|||||||
# it under the terms of the GNU General Public License version 2 as
|
# it under the terms of the GNU General Public License version 2 as
|
||||||
# published by the Free Software Foundation.
|
# published by the Free Software Foundation.
|
||||||
|
|
||||||
__version__ = "1.30.6"
|
__version__ = "1.30.7-dev"
|
||||||
__variant__ = None
|
__variant__ = None
|
||||||
|
|||||||
Reference in New Issue
Block a user