0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-15 14:31:11 +01:00

modules/console: Ensure different serializations available w/ raw/source arguments.

This commit is contained in:
Jason Volk 2020-05-12 23:23:37 -07:00
parent b4df449068
commit 525db9f5e3

View file

@ -7330,7 +7330,7 @@ console_cmd__event(opt &out, const string_view &line)
case hash("raw"): case hash("raw"):
{ {
if(event.source) if(event.source)
out << event.source << std::endl; out << json::strung{event.source} << std::endl;
else else
out << event << std::endl; out << event << std::endl;
@ -7340,7 +7340,7 @@ console_cmd__event(opt &out, const string_view &line)
case hash("source"): case hash("source"):
{ {
if(event.source) if(event.source)
out << event.source << std::endl; out << string_view{event.source} << std::endl;
return true; return true;
} }