From 01e25b1b0a19ec9121bd352f839f6a2fb9657032 Mon Sep 17 00:00:00 2001 From: Jordan Brown Date: Wed, 7 Jun 2017 16:18:09 -0400 Subject: [PATCH 1/3] IRC tagging now ignores a trailing colon --- TGServerService/IRC.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/TGServerService/IRC.cs b/TGServerService/IRC.cs index a53c74de05..126c85bbe9 100644 --- a/TGServerService/IRC.cs +++ b/TGServerService/IRC.cs @@ -88,7 +88,10 @@ namespace TGServerService var formattedMessage = e.Data.Message.Trim(); var splits = new List(formattedMessage.Split(' ')); - var tagged = splits[0].ToLower() == irc.Nickname.ToLower(); + var test = splits[0]; + if (test.Length > 1 && test[test.Length - 1] == ':') + test = test.SubString(0, test.Length - 1) + var tagged = test.ToLower() == irc.Nickname.ToLower(); if (tagged) { From a703b0aadd0999c9c5ab3e9661e202ce9defb15c Mon Sep 17 00:00:00 2001 From: Jordan Brown Date: Wed, 7 Jun 2017 16:19:02 -0400 Subject: [PATCH 2/3] Fix --- TGServerService/IRC.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TGServerService/IRC.cs b/TGServerService/IRC.cs index 126c85bbe9..9f4cebb51a 100644 --- a/TGServerService/IRC.cs +++ b/TGServerService/IRC.cs @@ -90,7 +90,7 @@ namespace TGServerService var splits = new List(formattedMessage.Split(' ')); var test = splits[0]; if (test.Length > 1 && test[test.Length - 1] == ':') - test = test.SubString(0, test.Length - 1) + test = test.SubString(0, test.Length - 1); var tagged = test.ToLower() == irc.Nickname.ToLower(); if (tagged) From a007fba6e6254a897126810a6aeb029a548776a7 Mon Sep 17 00:00:00 2001 From: Jordan Brown Date: Wed, 7 Jun 2017 16:21:54 -0400 Subject: [PATCH 3/3] Yep --- TGServerService/IRC.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TGServerService/IRC.cs b/TGServerService/IRC.cs index 9f4cebb51a..0fa400f62d 100644 --- a/TGServerService/IRC.cs +++ b/TGServerService/IRC.cs @@ -90,7 +90,7 @@ namespace TGServerService var splits = new List(formattedMessage.Split(' ')); var test = splits[0]; if (test.Length > 1 && test[test.Length - 1] == ':') - test = test.SubString(0, test.Length - 1); + test = test.Substring(0, test.Length - 1); var tagged = test.ToLower() == irc.Nickname.ToLower(); if (tagged)