mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-16 22:53:08 +01:00
Fixed non-relaying of QUITs.
This commit is contained in:
parent
59b6a7b67d
commit
d37e229027
@ -43,6 +43,7 @@ Commands include:
|
||||
from baseplugin import *
|
||||
|
||||
import re
|
||||
import copy
|
||||
|
||||
import ircdb
|
||||
import debug
|
||||
@ -98,8 +99,15 @@ class Relay(callbacks.Privmsg):
|
||||
self.ircs = {}
|
||||
self.started = False
|
||||
self.channels = set()
|
||||
self.ircstates = {}
|
||||
self.abbreviations = {}
|
||||
|
||||
def inFilter(self, irc, msg):
|
||||
if not isinstance(irc, irclib.Irc):
|
||||
irc = irc.getRealIrc()
|
||||
self.ircstates[irc] = copy.copy(irc.state)
|
||||
return msg
|
||||
|
||||
def startrelay(self, irc, msg, args):
|
||||
"""<network abbreviation for current server>
|
||||
|
||||
@ -298,7 +306,7 @@ class Relay(callbacks.Privmsg):
|
||||
else:
|
||||
s = '%s/%s has quit.' % (msg.nick, network)
|
||||
for channel in self.channels:
|
||||
if msg.nick in irc.state.channels[channel].users:
|
||||
if msg.nick in self.ircstates.channels[channel].users:
|
||||
for otherIrc in self.ircs.itervalues():
|
||||
if otherIrc != irc:
|
||||
otherIrc.queueMsg(ircmsgs.privmsg(channel, s))
|
||||
|
Loading…
Reference in New Issue
Block a user