Skip to content
This repository has been archived by the owner on Nov 11, 2023. It is now read-only.

Commit

Permalink
Merge pull request #381 from dcruzin/fix-anyof-response-body
Browse files Browse the repository at this point in the history
Fix allOf  in responseBodies generation
  • Loading branch information
micha-f authored Dec 27, 2021
2 parents c77e52e + d914ac4 commit 476f583
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/scripts/import-open-api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,9 @@ export const generateRestfulComponent = (
needAResponseComponent
? `
export ${
responseTypes.includes("|") ? `type ${componentName}Response =` : `interface ${componentName}Response`
responseTypes.includes("|") || responseTypes.includes("&")
? `type ${componentName}Response =`
: `interface ${componentName}Response`
} ${responseTypes}
`
: ""
Expand Down

0 comments on commit 476f583

Please sign in to comment.