Skip to content

Commit eca90ec

Browse files
committed
docs(onboarding): Clarify query vs exact match in repo lookup comment
1 parent 9138272 commit eca90ec

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

static/app/views/onboarding/components/useScmRepoSelection.ts

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,12 @@ export function useScmRepoSelection({
8080
queryFn: fetchDataQuery<Repository[]>,
8181
staleTime: 0,
8282
});
83-
// Match on Repository.name === IntegrationRepository.identifier.
84-
// This is the same comparison the backend uses in the search endpoint
85-
// (organization_integration_repos.py) to determine isInstalled.
86-
// Can't use externalSlug because it varies by provider (e.g. GitLab
87-
// returns a numeric project ID).
83+
// The query param above is an icontains filter to narrow results
84+
// and avoid pagination. The exact match here uses Repository.name
85+
// against IntegrationRepository.identifier — the same comparison the
86+
// backend uses in organization_integration_repos.py:61,80 to determine
87+
// isInstalled. Can't use externalSlug because it varies by provider
88+
// (e.g. GitLab returns a numeric project ID).
8889
const existing = matches?.find(r => r.name === repo.identifier);
8990

9091
if (existing) {

0 commit comments

Comments
 (0)