diff --git a/cffu-core/src/main/java/io/foldright/cffu/CompletableFutureUtils.java b/cffu-core/src/main/java/io/foldright/cffu/CompletableFutureUtils.java index d683be26..dac6cfb5 100644 --- a/cffu-core/src/main/java/io/foldright/cffu/CompletableFutureUtils.java +++ b/cffu-core/src/main/java/io/foldright/cffu/CompletableFutureUtils.java @@ -508,7 +508,7 @@ public static CompletableFuture> mostResultsOfSuccess( // 1. avoid writing it by `cffuOrTimeout` and is able to read its result(`getSuccessNow`) // 2. ensure that the returned cf is not minimal-stage CF instance(UnsupportedOperationException) final CompletableFuture f = toNonMinCfCopy(requireNonNull(cfs[0], "cf1 is null")); - return cffuOrTimeout(f, executorWhenTimeout, timeout, unit) + return cffuCompleteOnTimeout(f, valueIfNotSuccess, executorWhenTimeout, timeout, unit) .handle((unused, ex) -> arrayList(getSuccessNow(f, valueIfNotSuccess))); }