fix(router): prevent cross-team deployment leakage in fallback path

Guard should_include_deployment fallback to only return deployments
matching the requested team_id, preventing public-name collisions
from leaking deployments across teams

Made-with: Cursor
This commit is contained in:
Sameer Kankute 2026-03-23 17:00:30 +05:30 • committed by Yuneng Jiang
parent b932aac33a
commit ea00646d5c
No known key found for this signature in database

View file

@ -8221,7 +8221,8 @@ class Router:
):
return True
elif model_name is not None and model["model_name"] == model_name:
return True
if team_id is None or model["model_info"].get("team_id") == team_id:
return True
return False
def _get_all_deployments(