Skip to content

Commit a8c2cd7

Browse files
author
github-actions
committed
Google Java Format
1 parent bcb179c commit a8c2cd7

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

Queries.java

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import java.nio.file.OpenOption;
21
import java.util.ArrayList;
32
import java.util.Comparator;
43
import java.util.List;
@@ -25,12 +24,15 @@ public int getTotalOfAllGoalsByMidfielders() {
2524
}
2625

2726
public Optional<String> getNameOfVfLWolfsburgFootballerWithMostPlayedGames() {
28-
Predicate<Footballer> isFromWolfsburg = footballer -> footballer.footballClub()
29-
.equals(new FootballClub("VfL Wolfsburg", 3, 1145));
30-
Comparator<Footballer> sortNumberOfGoalsAscending = (footballer1, footballer2) -> Integer
31-
.valueOf(footballer1.numberOfGames()).compareTo(footballer2.numberOfGames());
27+
Predicate<Footballer> isFromWolfsburg =
28+
footballer -> footballer.footballClub().equals(new FootballClub("VfL Wolfsburg", 3, 1145));
29+
Comparator<Footballer> sortNumberOfGoalsAscending =
30+
(footballer1, footballer2) ->
31+
Integer.valueOf(footballer1.numberOfGames()).compareTo(footballer2.numberOfGames());
3232

33-
return footballers.stream().filter(isFromWolfsburg).max(sortNumberOfGoalsAscending)
33+
return footballers.stream()
34+
.filter(isFromWolfsburg)
35+
.max(sortNumberOfGoalsAscending)
3436
.map(footballer -> footballer.name());
3537
}
3638

0 commit comments

Comments
 (0)