Converted to use world.getIrc.

This commit is contained in:
Jeremy Fincher 2004-12-16 08:10:46 +00:00
parent 73deb2036c
commit 0c0f7915f5

View File

@ -55,11 +55,12 @@ class Network(callbacks.Privmsg):
_whois = {} _whois = {}
_latency = {} _latency = {}
def _getIrc(self, network): def _getIrc(self, network):
network = network.lower() irc = world.getIrc(network)
for irc in world.ircs: if irc:
if irc.network.lower() == network: return irc
return irc else:
raise callbacks.Error, 'I\'m not currently connected to %s.' % network raise callbacks.Error, \
'I\'m not currently connected to %s.' % network
def connect(self, irc, msg, args, network, server): def connect(self, irc, msg, args, network, server):
"""<network> [<host[:port]>] """<network> [<host[:port]>]