Catch exception in #[MapRequestBody]
during serialization
#60289
Unanswered
andrefpoliveira
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey!
I have the following controller
If the user sends
""
or some other input that it's not a JSON structure, I'm gettingNotEncodableValueException
, however I would like to catch that and send a custom exception. I already tried ExceptionListener, changing theservices.yaml
however it seems that I'm not able to catch it...Is there a way to do this?
Thank you!
Beta Was this translation helpful? Give feedback.
All reactions