mirror of
https://github.com/spacebarchat/server.git
synced 2024-11-10 12:42:44 +01:00
Fix messages?after=snowflake calling new Snowflake, which is not allwoed
This commit is contained in:
parent
11d57df801
commit
d1e3640157
@ -109,7 +109,7 @@ router.get("/", async (req: Request, res: Response) => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
if (after) {
|
if (after) {
|
||||||
if (after > new Snowflake()) return res.status(422);
|
if (after > Snowflake.generate()) return res.status(422);
|
||||||
query.where.id = MoreThan(after);
|
query.where.id = MoreThan(after);
|
||||||
}
|
}
|
||||||
else if (before) {
|
else if (before) {
|
||||||
|
Loading…
Reference in New Issue
Block a user