0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-10-01 13:18:58 +02:00

modules/federation: Minor cleanup/simplification.

This commit is contained in:
Jason Volk 2019-03-05 23:54:36 -08:00
parent c2966275c6
commit 09c2d7cbe5
6 changed files with 9 additions and 32 deletions

View file

@ -112,14 +112,9 @@ get__backfill(client &client,
};
json::stack::object top{out};
json::stack::member pdus_m
{
top, "pdus"
};
json::stack::array pdus
{
pdus_m
top, "pdus"
};
size_t count{0};

View file

@ -113,14 +113,9 @@ get__backfill_ids(client &client,
};
json::stack::object top{out};
json::stack::member pdus_m
{
top, "pdu_ids"
};
json::stack::array pdus
{
pdus_m
top, "pdu_ids"
};
size_t count{0};

View file

@ -66,14 +66,9 @@ handle_get(client &client,
};
json::stack::object top{out};
json::stack::member pdus_m
{
top, "pdus"
};
json::stack::array pdus
{
pdus_m
top, "pdus"
};
pdus.append(event);

View file

@ -81,14 +81,9 @@ get__event_auth(client &client,
};
json::stack::object top{out};
json::stack::member auth_chain_m
{
top, "auth_chain"
};
json::stack::array auth_chain
{
auth_chain_m
top, "auth_chain"
};
const m::event::auth::chain chain

View file

@ -119,14 +119,9 @@ get__missing_events(client &client,
};
json::stack::object top{out};
json::stack::member events_m
{
top, "events"
};
json::stack::array events
{
events_m
top, "events"
};
std::deque<std::string> queue;

View file

@ -95,8 +95,10 @@ handle_get(client &client,
m::room::id::buf next_batch_buf;
json::stack::object top{out};
{
json::stack::member chunk_m{top, "chunk"};
json::stack::array chunk{chunk_m};
json::stack::array chunk
{
top, "chunk"
};
const string_view &key
{