Skip to content

Commit

Permalink
feat: 이름 정렬 추가 (#58)
Browse files Browse the repository at this point in the history
  • Loading branch information
EunjiShin authored Jul 19, 2024
1 parent 23c1d22 commit 917c90d
Showing 1 changed file with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,8 @@ public List<StadiumHomeTeamInfo> findAllStadiums() {
.toList();
List<StadiumHomeTeamInfo> result = new ArrayList<>(immutableList);
result.sort(
new Comparator<>() {
@Override
public int compare(StadiumHomeTeamInfo o1, StadiumHomeTeamInfo o2) {
return Boolean.compare(o2.isActive(), o1.isActive());
}
});
Comparator.comparing((StadiumHomeTeamInfo info) -> !info.isActive())
.thenComparing(StadiumHomeTeamInfo::getName));
return result;
}

Expand Down

0 comments on commit 917c90d

Please sign in to comment.