diff --git a/jetty-util/src/main/java/org/eclipse/jetty/util/TypeUtil.java b/jetty-util/src/main/java/org/eclipse/jetty/util/TypeUtil.java index 2fccddc570ae..6ca9a524251a 100644 --- a/jetty-util/src/main/java/org/eclipse/jetty/util/TypeUtil.java +++ b/jetty-util/src/main/java/org/eclipse/jetty/util/TypeUtil.java @@ -752,6 +752,7 @@ public static boolean isUnboxable(Class type, Object arg) return true; Class c = __unbox.get(type); - return arg.getClass() == __unbox.get(type); + Class ac = arg.getClass(); + return ac == __unbox.get(type) || (Number.class.isAssignableFrom(c) && Number.class.isAssignableFrom(ac)); } }