From 4e60ea42415a5bfd828abb46ae366594337e85ce Mon Sep 17 00:00:00 2001 From: Kwoth Date: Sun, 2 Jan 2022 17:00:33 +0100 Subject: [PATCH] Fixed an extra whitespace in usage part of command help if the command has no arguments --- src/NadekoBot/_Extensions/Extensions.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/NadekoBot/_Extensions/Extensions.cs b/src/NadekoBot/_Extensions/Extensions.cs index 2de9aec4d..092121c2d 100644 --- a/src/NadekoBot/_Extensions/Extensions.cs +++ b/src/NadekoBot/_Extensions/Extensions.cs @@ -126,11 +126,11 @@ public static class Extensions IBotStrings strings, ulong? guildId, string prefix) - => Array.ConvertAll(strings.GetCommandStrings(cmd.Remarks, guildId).Args, + => Array.ConvertAll(strings.GetCommandStrings(cmd.Summary, guildId).Args, arg => GetFullUsage(cmd.Name, arg, prefix)); private static string GetFullUsage(string commandName, string args, string prefix) - => $"{prefix}{commandName} {string.Format(args, prefix)}"; + => $"{prefix}{commandName} {string.Format(args, prefix)}".TrimEnd(); public static IEmbedBuilder AddPaginatedFooter(this IEmbedBuilder embed, int curPage, int? lastPage) {