diff --git a/src/main/java/core/net/DownloadFilter.java b/src/main/java/core/net/DownloadFilter.java index f24a1c642..fc7575818 100644 --- a/src/main/java/core/net/DownloadFilter.java +++ b/src/main/java/core/net/DownloadFilter.java @@ -54,9 +54,7 @@ private void fillOldFixturesList(DefaultMutableTreeNode previousSeriesData) { int finalI = i; var season = seasons.stream().filter(f -> f.getSaison() == finalI).findFirst(); var itemText = new StringBuilder(TranslationFacility.tr("Season")).append(" ").append(i); - if (season.isPresent()) { - itemText.append(" / ").append(season.get().getLigaName()); - } + season.ifPresent(fixture -> itemText.append(" / ").append(fixture.getLigaName())); previousSeriesData.add(new DefaultMutableTreeNode(Pair.of(itemText.toString(), finalI))); } }