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: Use anyof and nullable: true for nullable unions w/refs #734

Merged
merged 1 commit into from
Jun 17, 2020

Conversation

fantapop
Copy link
Contributor

Using the " anyOf with nullable: true" form has the benefit that the
openapi typescript-fetch generator already has support for this
construct.

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Have you written unit tests?
  • Have you written unit tests that cover the negative cases (i.e.: if bad data is submitted, does the library respond properly)?
  • This PR is associated with an existing issue?

If this is a new feature submission:

  • Has the issue had a maintainer respond to the issue and clarify that the feature is something that aligns with the goals and philosophy of the project?

Potential Problems With The Approach

None that I'm aware

Test plan

I modified the existing test which was relevant to ensure the correct values were being returned

Using the "anyOf with nullable: true" form has the benefit that the
openapi typescript-fetch generator already has support for this
construct.
@fantapop fantapop mentioned this pull request Jun 15, 2020
4 tasks
@WoH WoH changed the title Use anyof and nullable: true for nullable unions w/refs Fix: Use anyof and nullable: true for nullable unions w/refs Jun 17, 2020
@WoH WoH merged commit c92c25c into lukeautry:master Jun 17, 2020
@WoH
Copy link
Collaborator

WoH commented Jun 17, 2020

I don't have a preference either way, so if this helps with client generation, LGTM.
Thank you!

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

Successfully merging this pull request may close these issues.

2 participants