Skip to content

Conversation

@ivan-aksamentov
Copy link
Contributor

PR checklist

  • Read the contribution guidelines.
  • Ran the shell script under ./bin/ to update Petstore sample so that CIs can verify the change. (For instance, only need to run ./bin/{LANG}-petstore.sh, ./bin/openapi3/{LANG}-petstore.sh if updating the {LANG} (e.g. php, ruby, python, etc) code generator or {LANG} client's mustache templates). Windows batch files can be found in .\bin\windows\. If contributing template-only or documentation-only changes which will change sample output, be sure to build the project first.
  • Filed the PR against the correct branch: master, 4.1.x, 5.0.x. Default: master.
  • Copied the technical committee to review the pull request if your PR is targeting a particular programming language.

Dear PHP technical committee, please review this PR
@jebentier @dkarlovi @mandrean @jfastnacht @ackintosh @ybelenko @renepardon

Description of the PR

This PR attempts to fix #3514
Short description: the return type of PHP Symfony actions is forced to be an array, while should be an object.

@ivan-aksamentov
Copy link
Contributor Author

Should I commit the results of running ./bin/openapi3/php-symfony-petstore.sh?
The produced sample is correct in terms of return types, but there are also changes that are not related to my PR, so I am hesitating. Looks like the symfony sample has not been updated for some time.

@wing328
Copy link
Member

wing328 commented Aug 1, 2019

@ivan-aksamentov thanks for the PR. Please commit the updated samples.

@ivan-aksamentov
Copy link
Contributor Author

ivan-aksamentov commented Aug 1, 2019

@wing328 done.
My confusion with samples was due to the fact, that both Swagger 2.0 and OpenAPI 3.0 samples are written into the same directory, overwriting each other. I submitted #3531 and #3532 to address that.

@wing328
Copy link
Member

wing328 commented Aug 1, 2019

@ivan-aksamentov you're right. Thanks for filing another PR to fix the sample location

Copy link
Member

@wing328 wing328 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@wing328 wing328 merged commit 581131e into OpenAPITools:master Aug 1, 2019
@wing328 wing328 added this to the 4.1.0 milestone Aug 9, 2019
@wing328
Copy link
Member

wing328 commented May 25, 2022

#11810 has been merged to support Symfony 6. Please give it a try and let us know if you've any feedback or question.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] PHP Symfony server generator forces return type of actions to be an array

2 participants