From 8bd4c6a91d8e18058cbbcd61a99c2319024b6c05 Mon Sep 17 00:00:00 2001 From: JustArchi Date: Mon, 20 Feb 2017 15:06:45 +0100 Subject: [PATCH] Code cleanup --- ArchiSteamFarm/Bot.cs | 54 +++++++++++++++++++++---------------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/ArchiSteamFarm/Bot.cs b/ArchiSteamFarm/Bot.cs index b0f068479..e51cbf0a4 100755 --- a/ArchiSteamFarm/Bot.cs +++ b/ArchiSteamFarm/Bot.cs @@ -303,6 +303,15 @@ namespace ArchiSteamFarm { } } + internal static string FormatBotResponse(string response, string botName) { + if (!string.IsNullOrEmpty(response)) { + return Environment.NewLine + "<" + botName + "> " + response; + } + + ASF.ArchiLogger.LogNullError(nameof(response)); + return null; + } + internal static string GetAPIStatus() { var response = new { Bots @@ -753,6 +762,24 @@ namespace ArchiSteamFarm { SteamClient.Disconnect(); } + private string FormatBotResponse(string response) { + if (!string.IsNullOrEmpty(response)) { + return Environment.NewLine + "<" + BotName + "> " + response; + } + + ASF.ArchiLogger.LogNullError(nameof(response)); + return null; + } + + private static string FormatStaticResponse(string response) { + if (!string.IsNullOrEmpty(response)) { + return Environment.NewLine + response; + } + + ASF.ArchiLogger.LogNullError(nameof(response)); + return null; + } + private static HashSet GetBots(string args) { if (string.IsNullOrEmpty(args)) { ASF.ArchiLogger.LogNullError(nameof(args)); @@ -2875,33 +2902,6 @@ namespace ArchiSteamFarm { return null; } - private string FormatBotResponse(string response) { - if (!string.IsNullOrEmpty(response)) { - return Environment.NewLine + "<" + BotName + "> " + response; - } - - ASF.ArchiLogger.LogNullError(nameof(response)); - return null; - } - - internal static string FormatBotResponse(string response, string botName) { - if (!string.IsNullOrEmpty(response)) { - return Environment.NewLine + "<" + botName + "> " + response; - } - - ASF.ArchiLogger.LogNullError(nameof(response)); - return null; - } - - private static string FormatStaticResponse(string response) { - if (!string.IsNullOrEmpty(response)) { - return Environment.NewLine + response; - } - - ASF.ArchiLogger.LogNullError(nameof(response)); - return null; - } - private void SendMessageToChannel(ulong steamID, string message) { if ((steamID == 0) || string.IsNullOrEmpty(message)) { ArchiLogger.LogNullError(nameof(steamID) + " || " + nameof(message));