Slight optimization in getCallback.

This commit is contained in:
Jeremy Fincher 2003-07-30 11:04:29 +00:00
parent 33f2818398
commit c6a8cebc2d

View File

@ -375,8 +375,9 @@ class Irc(object):
self.callbacks.append(callback) self.callbacks.append(callback)
def getCallback(self, name): def getCallback(self, name):
name = name.lower()
for callback in self.callbacks: for callback in self.callbacks:
if callback.name() == name: if callback.name().lower() == name:
return callback return callback
else: else:
return None return None