src/Viserio/Component/Parser/Parser/JsonParser.php
public function parse(string $payload): array
    {
        $json = \json_decode(\trim($payload), true, $this->depth, $this->options);

        if (\json_last_error() !== \JSON_ERROR_NONE) {
            throw new ParseException([
                'message' => \json_last_error_msg() . '.',
                'code'    => \json_last_error(),
                'file'    => $payload,
            ]);
        }

        return $json;
    }
public function parse(string $payload): array
    {
        $json = \json_decode(\trim($payload), true, $this->depth, $this->options);

        if (\json_last_error() !== \JSON_ERROR_NONE) {
            throw new ParseException([
                'message' => \json_last_error_msg() . '.',
                'code'    => \json_last_error(),
                'file'    => $payload,
            ]);
        }

        return $json;
    }
{@inheritdoc}