From e3d8215f2f2507d35d94f2948d8fa0a95130c030 Mon Sep 17 00:00:00 2001 From: debu-2 Date: Wed, 7 Oct 2026 03:22:34 +0530 Subject: [PATCH] setting, session and profile fix --- backend/app/services/session_policy.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/app/services/session_policy.py b/backend/app/services/session_policy.py index f2acd9e..3a0eb93 100644 --- a/backend/app/services/session_policy.py +++ b/backend/app/services/session_policy.py @@ -5,7 +5,6 @@ from __future__ import annotations from sqlalchemy.ext.asyncio import AsyncSession from app.models import Account -from app.services.org_security import get_or_create_security_settings DEFAULT_SESSION_TIMEOUT_MINUTES = 10_080 # 1 week @@ -42,6 +41,8 @@ async def resolve_session_timeout_minutes( ) -> int: timeout = account.session_timeout_minutes or DEFAULT_SESSION_TIMEOUT_MINUTES if account.company_domain: + from app.services.org_security import get_or_create_security_settings + org = await get_or_create_security_settings(session, account.company_domain) timeout = min(timeout, org.session_timeout_minutes) return timeout