Skip to content

Commit ad1a742

Browse files
authored
Add support for groups that have only digits in their names and contain no alphabetic characters (#467)
* replace the search for OWNER first search for OWNER type of group afterwards search for OWNER type of user * fix identification by running mvn spotless:apply
1 parent cae742b commit ad1a742

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/main/java/io/jenkins/plugins/gitlabbranchsource/GitLabSCMSource.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -960,13 +960,13 @@ public ListBoxModel doFillProjectPathItems(
960960
return new StandardListBoxModel().includeEmptyValue();
961961
}
962962
try {
963-
for (Project p : gitLabApi
964-
.getProjectApi()
965-
.getUserProjects(projectOwner, new ProjectFilter().withOwned(true))) {
963+
for (Project p : gitLabApi.getGroupApi().getProjects(projectOwner)) {
966964
result.add(p.getPathWithNamespace());
967965
}
968966
} catch (GitLabApiException e) {
969-
for (Project p : gitLabApi.getGroupApi().getProjects(projectOwner)) {
967+
for (Project p : gitLabApi
968+
.getProjectApi()
969+
.getUserProjects(projectOwner, new ProjectFilter().withOwned(true))) {
970970
result.add(p.getPathWithNamespace());
971971
}
972972
}

0 commit comments

Comments
 (0)