(js: JsonSchema.JsonSchema)
| 183 | |
| 184 | const exclude = excludeAnnotations ? new Set(excludeAnnotations) : undefined |
| 185 | const onEnter = (js: JsonSchema.JsonSchema): JsonSchema.JsonSchema => { |
| 186 | const out = { ...normalizeOpenEnum(js) } |
| 187 | if (exclude) { |
| 188 | for (const key of exclude) delete out[key] |
| 189 | } |
| 190 | if (disableAdditionalProperties && out.type === "object") { |
| 191 | out.additionalProperties = false |
| 192 | } |
| 193 | return out |
| 194 | } |
| 195 | |
| 196 | return yield* openApiGen |
| 197 | .generate(patchedSpec as unknown as Parameters<typeof openApiGen.generate>[0], { |
nothing calls this directly
no test coverage detected