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

[BUG] [typescript-fetch] Readonly properties are being Omitted in the wrong case #18587

Open
neon-john opened this issue May 7, 2024 · 0 comments

Comments

@neon-john
Copy link

Description

The generator emits objects with camelCase properties, but in cases where they should be omitted for being readonly, it omits them by snake_case, which is incorrect.

The issue was introduced in this change:
Omit readOnly properties from request models

The problem is visible in the sample output:
https://github.com/OpenAPITools/openapi-generator/blob/master/samples/client/petstore/typescript-fetch/builds/default-v3.0/models/Name.ts#L73

Name has a property snakeCase, but the generator outputs Omit<Name, "snake_case">.

openapi-generator version

7.5.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant