From dc3e21a19516cef21a69512367b46b30278b21fe Mon Sep 17 00:00:00 2001 From: Iris System Date: Sun, 28 Apr 2024 20:00:52 +1200 Subject: [PATCH] fix(bot): correct length check in ctx.CreateNotFoundError --- .../CommandSystem/Context/ContextEntityArgumentsExt.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PluralKit.Bot/CommandSystem/Context/ContextEntityArgumentsExt.cs b/PluralKit.Bot/CommandSystem/Context/ContextEntityArgumentsExt.cs index 4e334505..1f90d163 100644 --- a/PluralKit.Bot/CommandSystem/Context/ContextEntityArgumentsExt.cs +++ b/PluralKit.Bot/CommandSystem/Context/ContextEntityArgumentsExt.cs @@ -172,12 +172,12 @@ public static class ContextEntityArgumentsExt if (isIDOnlyQuery) { - if (input.Length == 5) + if (input.Length >= 5 && input.Length <= 6) return $"{entity} with ID \"{input}\" not found."; return $"{entity} not found. Note that a {entity.ToLower()} ID is 5 or 6 characters long."; } - if (input.Length == 5) + if (input.Length >= 5 && input.Length <= 6) return $"{entity} with ID or name \"{input}\" not found."; return $"{entity} with name \"{input}\" not found. Note that a {entity.ToLower()} ID is 5 or 6 characters long."; }