0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-07-03 17:28:18 +02:00

modules/console: Fix path traverse regression.

This commit is contained in:
Jason Volk 2019-02-07 23:40:13 -08:00
parent 298750125a
commit 2574ea72a5

View file

@ -9290,13 +9290,18 @@ console_cmd__fed__head(opt &out, const string_view &line)
request.in.content request.in.content
}; };
const json::object event
{
proto["event"]
};
out << "DEPTH " out << "DEPTH "
<< proto.get({"event", "depth"}) << event["depth"]
<< std::endl; << std::endl;
const json::array &prev_events const json::array &prev_events
{ {
proto.get({"event", "prev_events"}) event["prev_events"]
}; };
for(const json::array &prev_event : prev_events) for(const json::array &prev_event : prev_events)
@ -9314,7 +9319,7 @@ console_cmd__fed__head(opt &out, const string_view &line)
const json::array &auth_events const json::array &auth_events
{ {
proto.get({"event", "auth_events"}) event["auth_events"]
}; };
for(const json::array &auth_event : auth_events) for(const json::array &auth_event : auth_events)