diff --git a/TGServerService/ChatCommands.cs b/TGServerService/ChatCommands.cs index 55b92365f5..1025066cc2 100644 --- a/TGServerService/ChatCommands.cs +++ b/TGServerService/ChatCommands.cs @@ -65,12 +65,12 @@ namespace TGServerService class RootChatCommand : RootCommand { public RootChatCommand(List serverCommands) - { - if (serverCommands == null) - serverCommands = new List(); + { + Children = new Command[] { new PRsCommand(), new VersionCommand(), new RevisionCommand(), new ByondCommand(), new KekCommand() }; + if (serverCommands != null) + serverCommands.CopyTo(Children); + serverCommands = new List(); PrintHelpList = true; - serverCommands.AddRange(new Command[] { new PRsCommand(), new VersionCommand(), new RevisionCommand(), new ByondCommand(), new KekCommand() }); - Children = serverCommands.ToArray(); } } class RevisionCommand : ChatCommand