Skip to content

Commit

Permalink
Fix nullable params parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
andrii-balitskyi committed Jun 27, 2024
1 parent 8f83afb commit 9ea5be0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/nextlove/src/generators/lib/zod-openapi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ function parseNullable({
}: ParsingArgs<z.ZodNullable<OpenApiZodAny>>): SchemaObject {
const schema = generateSchema(zodRef.unwrap(), useOutput)
return merge(
{ ...schema, type: [schema.type, "null"] as SchemaObjectType[] },
{ ...schema, type: schema.type, nullable: true },
parseDescription(zodRef),
...schemas
)
Expand Down

0 comments on commit 9ea5be0

Please sign in to comment.