Skip to content

Commit

Permalink
description mapper consideres nillable meta data
Browse files Browse the repository at this point in the history
  • Loading branch information
heiko-braun committed Aug 7, 2012
1 parent 5f2e634 commit 62aa8ef
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,10 @@ public void map(Mapping mapping) {
final boolean required = att.getValue().hasDefined("required") ?
att.getValue().get("required").asBoolean() : false;

mapping.onAttribute(name, description, type, required);
final boolean nillable = att.getValue().hasDefined("nillable") ?
att.getValue().get("nillable").asBoolean() : true;

mapping.onAttribute(name, description, type, !nillable||required);
}

}
Expand Down

0 comments on commit 62aa8ef

Please sign in to comment.