Skip to content

Commit

Permalink
Codacy inspections
Browse files Browse the repository at this point in the history
  • Loading branch information
djperrefort committed Jul 23, 2024
1 parent 16da454 commit 9345703
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions keystone_client/authentication.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,14 +143,15 @@ def logout(self, timeout: int = None) -> None:
def refresh(self, force: bool = False, timeout: int = None) -> None:
"""Refresh the current session credetials if necessary
This method will do nothing and exit silently if the current session is not authenticated.
This method will do nothing and exit silently if the current session
has not been authenticated.
Args:
timeout: Seconds before the request times out
force: Refresh the access token even if it has not expired yet
"""

if not self.is_authenticated():
if self.jwt is None:
return

# Don't refresh the token if it's not necessary
Expand Down
2 changes: 1 addition & 1 deletion keystone_client/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
authentication, data retrieval, and data manipulation.
"""

from __future__ import annotations, annotations
from __future__ import annotations

from functools import partial
from typing import Literal, Union
Expand Down

0 comments on commit 9345703

Please sign in to comment.