Skip to content

Commit

Permalink
null boxed primitives roundtrip
Browse files Browse the repository at this point in the history
  • Loading branch information
laurgarn committed Sep 13, 2023
1 parent 1463fa8 commit 6f60b9c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/main/java/com/cedarsoftware/util/io/MetaUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -720,14 +720,18 @@ static Object[] fillArgs(Class[] argTypes, boolean useNull)
for (int i = 0; i < argTypes.length; i++)
{
final Class argType = argTypes[i];
if (isPrimitive(argType))
if (argType.isPrimitive())
{
values[i] = convert(argType, null);
}
else if (useNull)
{
values[i] = null;
}
else if (prims.contains(argType))
{
values[i] = convert(argType, null);
}
else
{
if (argType == String.class)
Expand Down

0 comments on commit 6f60b9c

Please # to comment.