Skip to content

Commit 293fcb1

Browse files
committed
Fix exception message in
org.apache.commons.collections4.functors.FunctorUtils.validate(Consumer<?>...)
1 parent 6af02ce commit 293fcb1

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

src/changes/changes.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,13 @@
2424
<body>
2525
<release version="4.5.1" date="YYYY-MM-DD" description="This is a feature and maintenance release. Java 8 or later is required.">
2626
<!-- FIX -->
27-
<action type="fix" dev="ggregory" due-to="Gary Gregory">org.apache.commons.collections4.map.AbstractReferenceMap.ReferenceEntry.toReference(ReferenceStrength, T, int) now throws IllegalArgumentException instead of Error</action>
27+
<action type="fix" dev="ggregory" due-to="Gary Gregory">org.apache.commons.collections4.map.AbstractReferenceMap.ReferenceEntry.toReference(ReferenceStrength, T, int) now throws IllegalArgumentException instead of Error.</action>
2828
<action type="fix" dev="ggregory" due-to="Eric Hubert, Gary Gregory">Remove deprecation annotation of org.apache.commons.collections4.Factory; this will be deprecated in 5.0 in favor of java.util.function.Supplier.</action>
2929
<action type="fix" dev="ggregory" due-to="Eric Hubert, Gary Gregory">Remove deprecation annotation of org.apache.commons.collections4.Predicate; this will be deprecated in 5.0 in favor of java.util.function.Predicate.</action>
3030
<action type="fix" dev="ggregory" due-to="Eric Hubert, Gary Gregory">Remove deprecation annotation of org.apache.commons.collections4.Transformer; this will be deprecated in 5.0 in favor of java.util.function.Function.</action>
3131
<action type="fix" dev="ggregory" due-to="Eric Hubert, Gary Gregory">Remove deprecation annotation of org.apache.commons.collections4.Closure; this will be deprecated in 5.0 in favor of java.util.function.Consumer.</action>
3232
<action type="fix" dev="ggregory" due-to="Sebastian Götz, Gary Gregory" issue="COLLECTIONS-874">MapUtils.getLongValue(Map, K, Function) returns a byte instead of a long.</action>
33+
<action type="fix" dev="ggregory" due-to="Gary Gregory">Fix exception message in org.apache.commons.collections4.functors.FunctorUtils.validate(Consumer...)</action>
3334
<!-- ADD -->
3435
<!-- UPDATE -->
3536
<action type="update" dev="ggregory" due-to="Gary Gregory, Dependabot">Bump org.apache.commons:commons-parent from 81 to 84 #612.</action>

src/main/java/org/apache/commons/collections4/functors/FunctorUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ static <T> Predicate<? super T>[] validate(final Collection<? extends java.util.
139139
* @param consumers the consumers to validate.
140140
*/
141141
static void validate(final Consumer<?>... consumers) {
142-
Objects.requireNonNull(consumers, "closures");
142+
Objects.requireNonNull(consumers, "consumers");
143143
for (int i = 0; i < consumers.length; i++) {
144144
if (consumers[i] == null) {
145145
throw new NullPointerException("closures[" + i + "]");

0 commit comments

Comments
 (0)