Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

revert: remove unused session store codes (#2329)

takatostd8672796b0b1
diff --git a/api/services/account_service.py b/api/services/account_service.py
index f921566d363..18f72f9ef7f 100644
--- a/api/services/account_service.py
+++ b/api/services/account_service.py
@@ -66,6 +66,7 @@ class AccountService:
account.current_tenant_id = tenant_account_join.tenant_id
else:
_create_tenant_for_account(account)
+ session['workspace_id'] = account.current_tenant_id
else:
account.current_tenant_id = workspace_id
else:
@@ -75,6 +76,7 @@ class AccountService:
account.current_tenant_id = tenant_account_join.tenant_id
else:
_create_tenant_for_account(account)
+ session['workspace_id'] = account.current_tenant_id
current_time = datetime.utcnow()
@@ -286,6 +288,7 @@ class TenantService:
# Set the current tenant for the account
account.current_tenant_id = tenant_account_join.tenant_id
+ session['workspace_id'] = account.current_tenant.id
@staticmethod
def get_tenant_members(tenant: Tenant) -> List[Account]: