File tree Expand file tree Collapse file tree 1 file changed +2
-7
lines changed
src/main/java/org/apache/commons/lang3 Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -1465,16 +1465,11 @@ public static Class<?>[] primitivesToWrappers(final Class<?>... classes) {
14651465 * </p>
14661466 *
14671467 * @param cls the class to convert, may be null.
1468- * @return the wrapper class for {@code cls} or {@code cls} if {@code cls} is not a primitive. {@code null} if null
1469- * input.
1468+ * @return the wrapper class for {@code cls} or {@code cls} if {@code cls} is not a primitive. {@code null} if null input.
14701469 * @since 2.1
14711470 */
14721471 public static Class <?> primitiveToWrapper (final Class <?> cls ) {
1473- Class <?> convertedClass = cls ;
1474- if (cls != null && cls .isPrimitive ()) {
1475- convertedClass = PRIMITIVE_WRAPPER_MAP .get (cls );
1476- }
1477- return convertedClass ;
1472+ return cls != null && cls .isPrimitive () ? PRIMITIVE_WRAPPER_MAP .get (cls ) : cls ;
14781473 }
14791474
14801475 /**
You can’t perform that action at this time.
0 commit comments