Refine GitHub endpoint filtering logic#1458
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR removes the GitHub organization name validation check from the ADO service endpoint lookup logic. Previously, the code would match service endpoints by both type (GitHub or GitHubProximaPipelines) and organization name. Now it only matches by type, allowing any GitHub service connection to be found regardless of the organization name configured in the endpoint.
Key Changes
- Removed the organization name check from
GetTeamProjectGithubAppIdmethod, simplifying the endpoint lookup to only verify the endpoint type
Unit Test Results 1 files 1 suites 10m 25s ⏱️ Results for commit 5157706. ♻️ This comment has been updated with latest results. |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
| (((string)x["type"]).Equals("GitHub", StringComparison.OrdinalIgnoreCase) && | ||
| ((string)x["name"]).Equals(githubOrg, StringComparison.OrdinalIgnoreCase)) || | ||
| (((string)x["type"]).Equals("GitHubProximaPipelines", StringComparison.OrdinalIgnoreCase) && | ||
| ((string)x["name"]).Equals(teamProject, StringComparison.OrdinalIgnoreCase))); |
There was a problem hiding this comment.
[nitpick] This logic change refines how GitHubProximaPipelines endpoints are matched and appears to be a bug fix (matching against teamProject instead of githubOrg). According to the coding guidelines (item 5), changes that impact users such as bug fixes should have a bullet point added to RELEASENOTES.md with a user-friendly description. Consider adding a note about this fix.
There was a problem hiding this comment.
@copilot open a new pull request to apply changes based on this feedback
|
Closing in favor of #1466 |
ThirdPartyNotices.txt(if applicable)Linked issue: #1453