We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Option
The Rust generator output String when I think it should have output Option<String> in the model.
String
Option<String>
4.0.0-beta2
openapi: "3.0.0" info: version: 0.0.0 title: Bug Report paths: /: get: responses: '200': description: "" content: application/json: schema: $ref: "#/components/schemas/Pages" components: schemas: Pages: required: - next properties: next: type: string nullable: true
openapi-generator generate -i bug-report.yml -g rust -o bug-report
Generate the client library.
#2269 #1766
The text was updated successfully, but these errors were encountered:
👍 Thanks for opening this issue! 🏷 I have applied any labels matching special text in your issue.
The team will review the labels and make any necessary changes.
Sorry, something went wrong.
What about using the {{#isNullable}}...{{/isNullable}} mustache tag to to include Option<...>??
{{#isNullable}}...{{/isNullable}}
Option<...>
Something like that?
Yup, that should work as we've implemented it in other generators. Let us know if you need help filing a PR. Thanks for your contribution.
Use Option for nullable fields in Rust (closes OpenAPITools#2337)
54eb284
a0d907c
No branches or pull requests
Description
The Rust generator output
String
when I think it should have outputOption<String>
in the model.openapi-generator version
4.0.0-beta2
OpenAPI declaration file content or url
Command line used for generation
openapi-generator generate -i bug-report.yml -g rust -o bug-report
Steps to reproduce
Generate the client library.
Related issues/PRs
#2269
#1766
The text was updated successfully, but these errors were encountered: