From 7e8e1f1b8c1dc9e49da5b17069e32ad8fe465adc Mon Sep 17 00:00:00 2001 From: Ske Date: Thu, 18 Jun 2020 17:40:51 +0200 Subject: [PATCH] Don't try paginating with empty results --- PluralKit.Bot/Utils/ContextUtils.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PluralKit.Bot/Utils/ContextUtils.cs b/PluralKit.Bot/Utils/ContextUtils.cs index ab7ca402..d8112337 100644 --- a/PluralKit.Bot/Utils/ContextUtils.cs +++ b/PluralKit.Bot/Utils/ContextUtils.cs @@ -119,7 +119,7 @@ namespace PluralKit.Bot { try { var msg = await ctx.Reply(embed: await MakeEmbedForPage(0)); - if (pageCount == 1) return; // If we only have one page, don't bother with the reaction/pagination logic, lol + if (pageCount <= 1) return; // If we only have one (or no) page, don't bother with the reaction/pagination logic, lol string[] botEmojis = { "\u23EA", "\u2B05", "\u27A1", "\u23E9", Emojis.Error }; var _ = msg.CreateReactionsBulk(botEmojis); // Again, "fork"