-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Cannot use decorated DeserializeListener
in v3.2 to accept application/x-www-form-urlencoded
form data
#1856
Comments
use |
@soyuka, Oh, did not know that. But still, can we fix the documentation at https://api-platform.com/docs/core/form-data/ to note that it is only working with |
Yes definitely, actually we should provide a documentation on how to do this with processors! I'll open an issue there thanks! |
Hello, so if I enable |
API Platform version(s) affected: 3.2.7
Description
After upgrading to v3.2 and switching
event_listeners_backward_compatibility_layer
tofalse
, the use of decoratedDeserializeListener
to supportapplication/x-www-form-urlencoded
we relied on stopped working.We followed the current actual guide on https://api-platform.com/docs/core/form-data/ to know if there is a fix, but it seems the guide has not been updated for 3.2.
How to reproduce
config/packages/api_platform.yaml
\App\Infrastructure\EventListener\ApiPlatform\DeserializeListener
The expected response: no error.
With
event_listeners_backward_compatibility_layer: true
it works as expected.Possible Solution
Have a way to ignore content negotiation mismatch error or a new way to support
application/x-www-form-urlencoded
withevent_listeners_backward_compatibility_layer: false
.Additional Context
Notably the decorated
DeserializeListener
gets called withevent_listeners_backward_compatibility_layer: false
(didn't expect that).Not sure if it is a bug, documentation issue, or both.
The text was updated successfully, but these errors were encountered: