You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Symfony\Polyfill\Php83::json_validate() attempts to decode as an object (which faiils) / requires setting JSON_OBJECT_AS_ARRAY flag (not necessary with php's native function)
$json = json_encode(array(
"\x00null" => 'JSON_ERROR_INVALID_PROPERTY_NAME',
'string' => 'valid json, but must be decoded as an array,
));
json_decode($json, true); // success as array
json_decode($json, false); // failure as obj
\Symfony\Polyfill\Php83::json_validate($json); // returns false
json_validate($json); // returns true
when using php's native json_validate, it is not necessary to set the JSON_OBJECT_AS_ARRAY flag