Skip to content

Commit

Permalink
Merge pull request #48 from st-yclee/main
Browse files Browse the repository at this point in the history
repository 목록 조회시 필터링 작업
  • Loading branch information
st-yclee authored Sep 25, 2024
2 parents 0bc72e2 + e5f08fb commit 62bdf66
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.stream.Collectors;

@Service
@RequiredArgsConstructor
Expand All @@ -16,9 +17,15 @@ public class NexusRepositoryService implements CommonRepositoryService {

@Override
public List<CommonRepository.RepositoryDto> getRepositoryList() {
return repositoryAdapterService.getRepositoryList();
return repositoryAdapterService.getRepositoryList().stream()
.filter(t -> "hosted".equals(t.getType()) &&
("docker".equals(t.getFormat()) ||
"raw".equals(t.getFormat()) ||
"helm".equals(t.getFormat())))
.collect(Collectors.toList());
}


@Override
public CommonRepository.RepositoryDto getRepositoryByName(String name) {
return repositoryAdapterService.getRepositoryByName(name);
Expand Down

0 comments on commit 62bdf66

Please sign in to comment.