fix(gitlab): update repository selection to use URL instead of name

- Changed the repository selection logic in SaveGitlabProvider and SaveGitlabProviderCompose components to use the repository URL for better accuracy.
- Updated the condition for displaying the selected repository in the CheckIcon component to compare against the gitlabPathNamespace instead of the repository name.
- Refactored the getGitlabRepositories function to simplify the group name check logic.
This commit is contained in:
Mauricio Siu
2025-07-06 13:56:58 -06:00
parent b2d01a2889
commit b9ee81aa59
3 changed files with 7 additions and 7 deletions

View File

@@ -253,13 +253,11 @@ export const getGitlabRepositories = async (gitlabId?: string) => {
const groupName = gitlabProvider.groupName?.toLowerCase();
if (groupName) {
const isIncluded = groupName
return groupName
.split(",")
.some((name) =>
full_path.toLowerCase().startsWith(name.trim().toLowerCase()),
);
return isIncluded && kind === "group";
}
return kind === "user";
});