Skip to content

Commit

Permalink
fix config error on startup
Browse files Browse the repository at this point in the history
Signed-off-by: Jens Langhammer <[email protected]>
  • Loading branch information
BeryJu committed Jan 24, 2025
1 parent 631d985 commit a5db8d8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion authentik/lib/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,8 @@ def get_int(self, path: str, default=0) -> int:
def get_optional_int(self, path: str, default=None) -> int | None:
"""Wrapper for get that converts value into int or None if set"""
value = self.get(path, default)

if value is UNSET:
return default
try:
return int(value)
except (ValueError, TypeError) as exc:
Expand Down

0 comments on commit a5db8d8

Please sign in to comment.