Skip to content

Commit

Permalink
fix: update swagger property type
Browse files Browse the repository at this point in the history
  • Loading branch information
glebbash committed May 27, 2021
1 parent 187e896 commit 7a93766
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions src/core.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,11 @@ export const compose = <T>(
maxLength ? ArrayMaxSize(maxLength) : noop,
def !== undefined ? Transform(({ value }) => (value === undefined ? def : value)) : noop,
ApiProperty({
...(!!isArray
? {
type: 'array',
items: apiPropertyOptions as never,
minLength,
maxLength,
}
: apiPropertyOptions),
...apiPropertyOptions,
minLength,
maxLength,
...(nullable && { nullable }),
isArray: !!isArray,
name,
description,
example,
Expand Down

0 comments on commit 7a93766

Please sign in to comment.