Skip to content

Commit

Permalink
adding kwarg to disable SSL cert verification
Browse files Browse the repository at this point in the history
  • Loading branch information
bigoulours committed Dec 30, 2023
1 parent 3059825 commit 05537df
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions slskd_api/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,14 @@ def __init__(self,
username: str = None,
password: str = None,
token: str = None,
verify_ssl: bool = True
):
api_url = reduce(urljoin, [f'{host}/', f'{url_base}/', f'api/{API_VERSION}'])

session = requests.Session()
session.hooks = {'response': lambda r, *args, **kwargs: r.raise_for_status()}
session.headers.update({'accept': '*/*'})
session.verify = verify_ssl

header = {}

Expand Down

0 comments on commit 05537df

Please sign in to comment.