diff --git a/MultiServerChat/MultiServerChat.cs b/MultiServerChat/MultiServerChat.cs index 99a1547..7e3c842 100644 --- a/MultiServerChat/MultiServerChat.cs +++ b/MultiServerChat/MultiServerChat.cs @@ -88,6 +88,7 @@ private object RestChat(RestVerbs verbs, IParameterCollection parameters, Secure return new RestObject(); } + private bool failure = false; private void OnChat(ServerChatEventArgs args) { if (!Config.SendChat) @@ -134,10 +135,15 @@ private void OnChat(ServerChatEventArgs args) var request = (HttpWebRequest)WebRequest.Create(uri); using (var res = request.GetResponse()) {} + failure = false; } catch (Exception) { - Log.Error("Failed to make request to other server, server is down?"); + if (!failure) + { + Log.Error("Failed to make request to other server, server is down?"); + failure = true; + } } } }