Merge pull request #36 from Cyberboss/Cyberboss-patch-1

IRC tagging now ignores a trailing colon
This commit is contained in:
Remie Richards
2017-06-07 21:25:59 +01:00
committed by GitHub
+4 -1
View File
@@ -88,7 +88,10 @@ namespace TGServerService
var formattedMessage = e.Data.Message.Trim();
var splits = new List<string>(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)
{