From 36dcaf0c507ca7a4cc4e1117a760c12ac0b22eb4 Mon Sep 17 00:00:00 2001 From: Norman Maurer Date: Thu, 22 Apr 2021 08:22:37 +0200 Subject: [PATCH] Fix typo in exception message --- .../java/io/netty/util/internal/ObjectUtil.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/common/src/main/java/io/netty/util/internal/ObjectUtil.java b/common/src/main/java/io/netty/util/internal/ObjectUtil.java index 2a4b44897a..f7917087ed 100644 --- a/common/src/main/java/io/netty/util/internal/ObjectUtil.java +++ b/common/src/main/java/io/netty/util/internal/ObjectUtil.java @@ -189,7 +189,7 @@ public final class ObjectUtil { public static T[] checkNonEmpty(T[] array, String name) { //No String concatenation for check if (checkNotNull(array, name).length == 0) { - throw new IllegalArgumentException("Param '" + name + "' must not be emtpy"); + throw new IllegalArgumentException("Param '" + name + "' must not be empty"); } return array; } @@ -202,7 +202,7 @@ public final class ObjectUtil { public static byte[] checkNonEmpty(byte[] array, String name) { //No String concatenation for check if (checkNotNull(array, name).length == 0) { - throw new IllegalArgumentException("Param '" + name + "' must not be emtpy"); + throw new IllegalArgumentException("Param '" + name + "' must not be empty"); } return array; } @@ -215,7 +215,7 @@ public final class ObjectUtil { public static char[] checkNonEmpty(char[] array, String name) { //No String concatenation for check if (checkNotNull(array, name).length == 0) { - throw new IllegalArgumentException("Param '" + name + "' must not be emtpy"); + throw new IllegalArgumentException("Param '" + name + "' must not be empty"); } return array; } @@ -228,7 +228,7 @@ public final class ObjectUtil { public static > T checkNonEmpty(T collection, String name) { //No String concatenation for check if (checkNotNull(collection, name).size() == 0) { - throw new IllegalArgumentException("Param '" + name + "' must not be emtpy"); + throw new IllegalArgumentException("Param '" + name + "' must not be empty"); } return collection; } @@ -240,7 +240,7 @@ public final class ObjectUtil { */ public static String checkNonEmpty(final String value, final String name) { if (checkNotNull(value, name).isEmpty()) { - throw new IllegalArgumentException("Param '" + name + "' must not be emtpy"); + throw new IllegalArgumentException("Param '" + name + "' must not be empty"); } return value; } @@ -252,7 +252,7 @@ public final class ObjectUtil { */ public static > T checkNonEmpty(T value, String name) { if (checkNotNull(value, name).isEmpty()) { - throw new IllegalArgumentException("Param '" + name + "' must not be emtpy"); + throw new IllegalArgumentException("Param '" + name + "' must not be empty"); } return value; } @@ -264,7 +264,7 @@ public final class ObjectUtil { */ public static CharSequence checkNonEmpty(final CharSequence value, final String name) { if (checkNotNull(value, name).length() == 0) { - throw new IllegalArgumentException("Param '" + name + "' must not be emtpy"); + throw new IllegalArgumentException("Param '" + name + "' must not be empty"); } return value; }