diff --git a/tipbot/modules/irc.py b/tipbot/modules/irc.py index 15258aa..2b2d50c 100644 --- a/tipbot/modules/irc.py +++ b/tipbot/modules/irc.py @@ -31,7 +31,7 @@ def GetNick(data): # Return Nickname nick = nick.replace(':', ' ') nick = nick.replace(' ', '') nick = nick.strip(' \t\n\r') - return nick + return nick.lower() class IRCNetwork(Network): def __init__(self,name): @@ -354,7 +354,7 @@ class IRCNetwork(Network): log_log("New list of users in %s: %s" % (chan, str(self.userstable[chan].keys()))) elif action == 'KICK': - nick = parts[3] + nick = parts[3].lower() log_info('%s was kicked' % nick) removed_list = "" for chan in self.userstable: diff --git a/tipbot/utils.py b/tipbot/utils.py index d93bc72..a6a4667 100644 --- a/tipbot/utils.py +++ b/tipbot/utils.py @@ -236,13 +236,14 @@ def RetrieveBalance(link): def IdentityFromString(link,s): if s.find(':') == -1: - network = link.network.name + network = link.network nick=s else: parts=s.split(':') - network=parts[0] + network_name=parts[0] + network=GetNetworkByName(network_name) nick=parts[1] - return network+':'+nick + return network.name+':'+network.canonicalize(nick) def NickFromIdentity(identity): return identity.split(':')[1]