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

feat(#2297): (Symfony 7.1) Add MapRequestPayload array parameter handling #2298

Merged

Conversation

mazumba
Copy link
Contributor

@mazumba mazumba commented Jun 12, 2024

Q A
Bug fix? no
New feature? yes
Deprecations? no
Issues Fix #2297

With Symfony 7.1, a new type parameter has been introduced for MapRequestPayload that allows array Controller parameters to be resolved. This currently leads to an error when the Describer tries to register a new Model, because the parameter type array is used in this case. To resolve the issue, the given type parameter form the MapRequestPayload should be used instead.

I tried to test this as gracefully as possible. Any more elegant suggestions are welcome!

@mazumba mazumba changed the title [#2297] Add MapRequestPayload array parameter handling [#2297] Symfony 7.1 - Add MapRequestPayload array parameter handling Jun 12, 2024
@mazumba
Copy link
Contributor Author

mazumba commented Jun 12, 2024

Not sure if skipping the test is correct in this case. And I noticed that I was maybe a tiny bit too early with this, since 7.1 is fairly fresh 😅

@DjordyKoert
Copy link
Collaborator

Not sure if skipping the test is correct in this case.

It is 😉

And I noticed that I was maybe a tiny bit too early with this, since 7.1 is fairly fresh 😅

You can't start early enough, thanks a lot!

@mazumba
Copy link
Contributor Author

mazumba commented Jun 13, 2024

I would love this to also be merged into the 4.x branch. Do I just create a new PR with 100% successful checks into the 4.x branch?

@mazumba mazumba changed the title [#2297] Symfony 7.1 - Add MapRequestPayload array parameter handling [#2297] fix: Symfony 7.1 - Add MapRequestPayload array parameter handling Jun 17, 2024
@mazumba mazumba changed the title [#2297] fix: Symfony 7.1 - Add MapRequestPayload array parameter handling fix(#2297): Symfony 7.1 - Add MapRequestPayload array parameter handling Jun 17, 2024
@mazumba mazumba changed the title fix(#2297): Symfony 7.1 - Add MapRequestPayload array parameter handling fix(#2297): (Symfony 7.1) Add MapRequestPayload array parameter handling Jun 17, 2024
@DjordyKoert DjordyKoert changed the title fix(#2297): (Symfony 7.1) Add MapRequestPayload array parameter handling feat(#2297): (Symfony 7.1) Add MapRequestPayload array parameter handling Jun 19, 2024
@DjordyKoert DjordyKoert merged commit 684391a into nelmio:master Jun 19, 2024
17 checks passed
@DjordyKoert
Copy link
Collaborator

Thank you @mazumba :)

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.

[Bug]: Symfony 7.1 - MapRequestPayload resolves array with new "type" parameter
2 participants