Skip to content

Commit

Permalink
Set a default of 30 for access token expiration
Browse files Browse the repository at this point in the history
(and solve a mypy type annotation warning)
  • Loading branch information
augusto-herrmann committed Feb 3, 2025
1 parent e31c309 commit 78e78d7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@
import schemas
from util import check_permissions

ACCESS_TOKEN_EXPIRE_MINUTES = int(os.environ.get("ACCESS_TOKEN_EXPIRE_MINUTES"))
DEFAULT_TOKEN_EXPIRE_MINS = 30
ACCESS_TOKEN_EXPIRE_MINUTES = int(
os.environ.get("ACCESS_TOKEN_EXPIRE_MINUTES", DEFAULT_TOKEN_EXPIRE_MINS)
)
TEST_ENVIRONMENT = os.environ.get("TEST_ENVIRONMENT", "False") == "True"

# ## INIT --------------------------------------------------
Expand Down

0 comments on commit 78e78d7

Please sign in to comment.