0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-26 08:42:34 +01:00

modules/client/rooms/messages: Omit pagination tokens at ends of iteration.

This commit is contained in:
Jason Volk 2019-03-09 18:52:48 -08:00
parent 77896456c4
commit bfc189da7e

View file

@ -159,15 +159,17 @@ get__messages(client &client,
}
chunk.~array();
json::stack::member
{
top, "start", json::value{start}
};
if(it || page.dir == 'b')
json::stack::member
{
top, "start", json::value{start}
};
json::stack::member
{
top, "end", json::value{end}
};
if(it || page.dir != 'b')
json::stack::member
{
top, "end", json::value{end}
};
return {};
}