1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-06-01 04:18:14 +00:00

jp: Print double-quotes around string values in output

This commit is contained in:
Andreas Kling 2019-11-29 21:35:01 +01:00
parent ef32c71683
commit f60c40ab2e

View file

@ -66,6 +66,10 @@ void print(const JsonValue& value, int indent)
printf("\033[32;1m");
else if (value.is_null() || value.is_undefined())
printf("\033[34;1m");
if (value.is_string())
putchar('"');
printf("%s", value.to_string().characters());
if (value.is_string())
putchar('"');
printf("\033[0m");
}