Skip to content

Commit 4ed9a64

Browse files
committed
rm redundant check.
1 parent 6fcdacf commit 4ed9a64

1 file changed

Lines changed: 0 additions & 1 deletion

File tree

express-zod-api/src/documentation-helpers.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,6 @@ export const depictUnion: Depicter = ({ zodSchema, jsonSchema }) => {
119119
return jsonSchema;
120120
if (!("discriminator" in zodSchema._zod.def)) return jsonSchema;
121121
const propertyName: string = zodSchema._zod.def.discriminator;
122-
if (!propertyName) return jsonSchema;
123122
return {
124123
...jsonSchema,
125124
discriminator: jsonSchema.discriminator ?? { propertyName },

0 commit comments

Comments
 (0)