Re: RFC json_validate() - status: Under Discussion
| From: | juan carlos morales | Date: | Thu, 25 Aug 2022 21:03:18 +0000 |
| Subject: | Re: RFC json_validate() - status: Under Discussion | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-118475@lists.php.net to get a copy of this message | ||
Hello Rowan thanks for participating.
My answer for your comments would be:
=== Regarding JSON_THROW_ON_ERROR ===
I think is a valid point from your side, and I am open to change the
implementation if the maintainers believe so. I leave it there as it
existed in json_decode() and wanted to give the developer the option to use
it or not. But as I said, you hae a valid point, that I also like.
=== Regarding the examples you mentioned ===
The one from humhub and Symfony http-kernel, yes you are right, I will take
them out from the RFC right now. Nice catch.
But the Magento one, I took a look again, and I still believe is right
example, because the only reason is using json_decode() for, is to validate
only. Am I missing something here?
Regards.
RFC: https://wiki.php.net/rfc/json_validate
Implementation: https://github.com/php/php-src/pull/9399