Skip to content

Commit

Permalink
victools#484 remove redundant checked condition by getArraySchemaType…
Browse files Browse the repository at this point in the history
…Annotation
  • Loading branch information
dcdh committed Oct 16, 2024
1 parent c19718d commit e604d73
Showing 1 changed file with 0 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -373,9 +373,6 @@ protected BigDecimal resolveInclusiveMinimum(MemberScope<?, ?> member) {
* @return the {@code @ArraySchema(minItems)} value, otherwise {@code null}
*/
protected Integer resolveArrayMinItems(MemberScope<?, ?> member) {
if (member.isFakeContainerItemScope()) {
return null;
}
return this.getArraySchemaTypeAnnotation(member)
.map(Schema::minItems)
.filter(minItems -> minItems != Integer.MAX_VALUE)
Expand All @@ -389,9 +386,6 @@ protected Integer resolveArrayMinItems(MemberScope<?, ?> member) {
* @return the {@code @ArraySchema(maxItems)} value, otherwise {@code null}
*/
protected Integer resolveArrayMaxItems(MemberScope<?, ?> member) {
if (member.isFakeContainerItemScope()) {
return null;
}
return this.getArraySchemaTypeAnnotation(member)
.map(Schema::maxItems)
.filter(maxItems -> maxItems != Integer.MIN_VALUE)
Expand All @@ -405,9 +399,6 @@ protected Integer resolveArrayMaxItems(MemberScope<?, ?> member) {
* @return whether {@code @ArraySchema(uniqueItems = true)} is present
*/
protected Boolean resolveArrayUniqueItems(MemberScope<?, ?> member) {
if (member.isFakeContainerItemScope()) {
return null;
}
return this.getArraySchemaTypeAnnotation(member)
.map(Schema::uniqueItems)
.filter(uniqueItemsFlag -> uniqueItemsFlag)
Expand Down

0 comments on commit e604d73

Please sign in to comment.