Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bug: Unable to use {service-name} interpolation for filenames with openapi3-emitter when only one service is defined #6182

Merged
merged 12 commits into from
Mar 3, 2025
Prev Previous commit
Next Next commit
remove new helpers
  • Loading branch information
albertxavier100 committed Feb 28, 2025
commit 1bcacbff97fb513bf0e157e9125c6d8dd7cfed8c
4 changes: 0 additions & 4 deletions packages/openapi3/test/works-for.ts
Original file line number Diff line number Diff line change
@@ -3,7 +3,6 @@ import { OpenAPIVersion } from "../src/lib.js";
import {
checkFor,
diagnoseOpenApiFor,
emitOpenApi,
emitOpenApiWithDiagnostics,
oapiForModel,
openApiFor,
@@ -25,7 +24,6 @@ export type SpecHelper = {
checkFor: typeof checkFor;
diagnoseOpenApiFor: typeof diagnoseOpenApiFor;
emitOpenApiWithDiagnostics: typeof emitOpenApiWithDiagnostics;
emitOpenApi: typeof emitOpenApi;
objectSchemaIndexer: ObjectSchemaIndexer;
};

@@ -47,8 +45,6 @@ function createSpecHelpers(version: OpenAPIVersion): SpecHelper {
emitOpenApiWithDiagnostics: (
...[code, options]: Parameters<typeof emitOpenApiWithDiagnostics>
) => emitOpenApiWithDiagnostics(code, { ...options, "openapi-versions": [version] }),
emitOpenApi: (...[code, options]: Parameters<typeof emitOpenApi>) =>
emitOpenApi(code, { ...options, "openapi-versions": [version] }),
objectSchemaIndexer: version === "3.0.0" ? "additionalProperties" : "unevaluatedProperties",
};
}
Loading
Oops, something went wrong.