🐛 fix(session): correct middleware configuration parameter

- rename cookie_name to session_cookie to match correct FastAPI middleware parameter
- ensure session management functions as expected
This commit is contained in:
nocci 2025-12-06 13:18:13 +00:00
parent 036749ef07
commit 8f17f9bf8d

View file

@ -45,7 +45,7 @@ app.add_middleware(
secret_key=SESSION_SECRET, secret_key=SESSION_SECRET,
same_site="lax", same_site="lax",
https_only=SESSION_COOKIE_SECURE, https_only=SESSION_COOKIE_SECURE,
cookie_name="fleetledger_session", session_cookie="fleetledger_session",
max_age=60 * 60 * 24 * 30, # 30 days max_age=60 * 60 * 24 * 30, # 30 days
) )