0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-05-16 01:43:49 +02:00

modules/federation/send_leave: Implement v2.

This commit is contained in:
Jason Volk 2023-03-06 18:42:37 -08:00
parent 9aaae46ead
commit 1d58cd2266

View file

@ -113,14 +113,22 @@ put__send_leave(client &client,
event, vmopts
};
static const json::array &response
static const json::value responses[]
{
"[200,{}]"
{ "[200,{}]", json::ARRAY },
{ "{}", json::OBJECT },
};
const json::value &response
{
request.version == "v1"?
responses[0]:
responses[1]
};
return m::resource::response
{
client, http::OK, response
client, response
};
}