Skip to content

Commit

Permalink
Fixed: A default fulfils requirement, but does not count as assignment.
Browse files Browse the repository at this point in the history
  • Loading branch information
mkarg committed Dec 13, 2023
1 parent d7ec08c commit c6014dc
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/main/java/com/beust/jcommander/JCommander.java
Original file line number Diff line number Diff line change
Expand Up @@ -852,7 +852,6 @@ else if (commands.isEmpty()) {
// but the one assigned on the variable initialization), make it as assigned and
// remove it from the list of parameters to be required
if (parameterDescription.getDefault() != null && !parameterDescription.getParameterized().getType().isPrimitive()) {
fields.get(parameterDescription.getParameterized()).setAssigned(true);
requiredFields.remove(parameterDescription.getParameterized());
}
}
Expand Down

0 comments on commit c6014dc

Please sign in to comment.