From 6dc9dd53037234940372879db9f74695c2f1e41d Mon Sep 17 00:00:00 2001 From: Madeline <46743919+MaddyUnderStars@users.noreply.github.com> Date: Mon, 7 Aug 2023 20:31:36 +1000 Subject: fix reversed check in GET messages --- src/api/routes/channels/#channel_id/messages/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/api/routes/channels/#channel_id/messages/index.ts b/src/api/routes/channels/#channel_id/messages/index.ts index edc0321c..c384a05b 100644 --- a/src/api/routes/channels/#channel_id/messages/index.ts +++ b/src/api/routes/channels/#channel_id/messages/index.ts @@ -134,7 +134,7 @@ router.get( return res.status(422); query.where.id = MoreThan(after); } else if (before) { - if (BigInt(before) < BigInt(Snowflake.generate())) + if (BigInt(before) > BigInt(Snowflake.generate())) return res.status(422); query.where.id = LessThan(before); } -- cgit 1.4.1