Skip to content

Commit

Permalink
replace lamba with method reference
Browse files Browse the repository at this point in the history
  • Loading branch information
bmscomp committed Oct 5, 2023
1 parent ac5940e commit 0ba2ee8
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ protected List<Dependency> forcedDependencies(LaunchMode mode) {
List<Dependency> dependencies = new ArrayList<>();
MavenProject project = mavenProject();
Deployer deployer = getDeployer();
deployer.getExtensionArtifact(project).ifPresent(d -> dependencies.add(d));
deployer.getExtensionArtifact(project).ifPresent(dependencies::add);
if (this.imageBuild || this.imageBuilder != null) {
Set<ImageBuilder> projectBuilders = ImageBuilder.getProjectBuilder(project).stream().map(ImageBuilder::valueOf)
.collect(Collectors.toSet());
Optional<ImageBuilder> imageBuilder = ImageBuilder.getBuilder(this.imageBuilder, projectBuilders);
imageBuilder.filter(b -> !projectBuilders.contains(b)).flatMap(b -> b.getExtensionArtifact(project))
.ifPresent(d -> dependencies.add(d));
.ifPresent(dependencies::add);
}
return dependencies;
}
Expand Down

0 comments on commit 0ba2ee8

Please sign in to comment.