In this PR, we include the input string that is fed to json_decode, because it will help understanding issues with it.
What problem is this fixing?
This helper is used in a single place, to decode the response coming from Algolia. If the response is invalid, the contents of the input string is lost, making it impossible to troubleshoot the error.
Here is an example of what I am currently experiencing in my application:
json_decode error: Control character error, possibly incorrectly encoded
I don't think there is a way for me to troubleshoot this.
Describe your change
In this PR, we include the input string that is fed to
json_decode
, because it will help understanding issues with it.What problem is this fixing?
This helper is used in a single place, to decode the response coming from Algolia. If the response is invalid, the contents of the input string is lost, making it impossible to troubleshoot the error.
Here is an example of what I am currently experiencing in my application:
json_decode error: Control character error, possibly incorrectly encoded
I don't think there is a way for me to troubleshoot this.