mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-25 04:02:46 +01:00
Finally found the underlying cause of the relaynames bug.
This commit is contained in:
parent
82bb295b20
commit
f2ae4b5f34
@ -296,7 +296,7 @@ class IrcState(IrcCommandDispatcher):
|
|||||||
chan.topic = msg.args[2]
|
chan.topic = msg.args[2]
|
||||||
|
|
||||||
def doNick(self, irc, msg):
|
def doNick(self, irc, msg):
|
||||||
newNick = msg.args[0]
|
newNick = nick(msg.args[0])
|
||||||
oldNick = msg.nick
|
oldNick = msg.nick
|
||||||
try:
|
try:
|
||||||
if msg.user and msg.host:
|
if msg.user and msg.host:
|
||||||
|
@ -79,8 +79,11 @@ class IrcMsg(object):
|
|||||||
self._user = user
|
self._user = user
|
||||||
self._host = host
|
self._host = host
|
||||||
self._command = command
|
self._command = command
|
||||||
|
if self.command == 'NICK':
|
||||||
|
self._args[0] = ircutils.nick(self._args[0])
|
||||||
self._args = tuple(args)
|
self._args = tuple(args)
|
||||||
|
|
||||||
|
|
||||||
prefix = property(lambda self: self._prefix)
|
prefix = property(lambda self: self._prefix)
|
||||||
nick = property(lambda self: self._nick)
|
nick = property(lambda self: self._nick)
|
||||||
user = property(lambda self: self._user)
|
user = property(lambda self: self._user)
|
||||||
|
@ -235,8 +235,15 @@ def shrinkList(L, sep='', limit=425):
|
|||||||
class nick(str):
|
class nick(str):
|
||||||
"""This class does case-insensitive comparisons of nicks."""
|
"""This class does case-insensitive comparisons of nicks."""
|
||||||
def __init__(self, s):
|
def __init__(self, s):
|
||||||
|
self.original = s
|
||||||
self.lowered = toLower(s)
|
self.lowered = toLower(s)
|
||||||
|
|
||||||
|
def __repr__(self):
|
||||||
|
return repr(self.original)
|
||||||
|
|
||||||
|
def __str__(self):
|
||||||
|
return str(self.original)
|
||||||
|
|
||||||
def __eq__(self, s):
|
def __eq__(self, s):
|
||||||
try:
|
try:
|
||||||
return toLower(s) == self.lowered
|
return toLower(s) == self.lowered
|
||||||
|
Loading…
Reference in New Issue
Block a user