Skip to content

Commit

Permalink
Made the collector more readable
Browse files Browse the repository at this point in the history
  • Loading branch information
Hakky54 committed Sep 1, 2024
1 parent db67c18 commit 8d12fd1
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
import nl.altindag.ssl.util.SSLParametersUtils;
import nl.altindag.ssl.util.SSLSessionUtils;
import nl.altindag.ssl.util.TrustManagerUtils;
import nl.altindag.ssl.util.internal.CollectorsUtils;
import nl.altindag.ssl.util.internal.StringUtils;
import nl.altindag.ssl.util.internal.UriUtils;
import org.slf4j.Logger;
Expand Down Expand Up @@ -81,6 +80,7 @@

import static java.util.Objects.isNull;
import static java.util.Objects.nonNull;
import static nl.altindag.ssl.util.internal.CollectorsUtils.toListAndThen;
import static nl.altindag.ssl.util.internal.CollectorsUtils.toStringArray;
import static nl.altindag.ssl.util.internal.ValidationUtils.requireNotBlank;
import static nl.altindag.ssl.util.internal.ValidationUtils.requireNotEmpty;
Expand Down Expand Up @@ -893,7 +893,7 @@ private void trustCertificateChains() {
.map(KeyStoreUtils::getCertificateChains)
.flatMap(aliasToCertificateChain -> aliasToCertificateChain.values().stream())
.flatMap(Collection::stream)
.collect(CollectorsUtils.toListAndThen(KeyStoreUtils::createTrustStore));
.collect(toListAndThen(KeyStoreUtils::createTrustStore));

if (KeyStoreUtils.containsTrustMaterial(trustStore)) {
trustStores.add(trustStore);
Expand Down

0 comments on commit 8d12fd1

Please sign in to comment.