Skip to content

Commit

Permalink
optional orElse instead of orElseGet
Browse files Browse the repository at this point in the history
  • Loading branch information
pmossman committed Feb 10, 2022
1 parent b02755f commit 17856f0
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -469,7 +469,7 @@ public KubePodProcess(final boolean isOrchestrator,

final Pod pod = podBuilder.withTolerations(buildPodTolerations(tolerations))
.withImagePullSecrets(new LocalObjectReference(imagePullSecret)) // An empty string turns this into a no-op setting.
.withNodeSelector(nodeSelectors.orElseGet(null))
.withNodeSelector(nodeSelectors.orElse(null))
.withRestartPolicy("Never")
.withInitContainers(init)
.withContainers(containers)
Expand Down

0 comments on commit 17856f0

Please sign in to comment.