mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-26 20:59:27 +01:00
Fixes ProgVal/Limnoria#611
This commit is contained in:
parent
9210aa1a33
commit
f9afcffb3a
@ -230,9 +230,10 @@ class Owner(callbacks.Plugin):
|
|||||||
world.starting = False
|
world.starting = False
|
||||||
|
|
||||||
def do376(self, irc, msg):
|
def do376(self, irc, msg):
|
||||||
msg = conf.supybot.networks.get(irc.network).channels.joins()
|
msgs = conf.supybot.networks.get(irc.network).channels.joins()
|
||||||
if msg:
|
if msgs:
|
||||||
irc.queueMsg(msg)
|
for msg in msgs:
|
||||||
|
irc.queueMsg(msg)
|
||||||
do422 = do377 = do376
|
do422 = do377 = do376
|
||||||
|
|
||||||
def setFloodQueueTimeout(self, *args, **kwargs):
|
def setFloodQueueTimeout(self, *args, **kwargs):
|
||||||
|
15
src/conf.py
15
src/conf.py
@ -276,6 +276,9 @@ class SpaceSeparatedSetOfChannels(registry.SpaceSeparatedListOf):
|
|||||||
channels = []
|
channels = []
|
||||||
channels_with_key = []
|
channels_with_key = []
|
||||||
keys = []
|
keys = []
|
||||||
|
old = None
|
||||||
|
msgs = []
|
||||||
|
msg = None
|
||||||
for channel in self():
|
for channel in self():
|
||||||
key = self.key.get(channel)()
|
key = self.key.get(channel)()
|
||||||
if key:
|
if key:
|
||||||
@ -283,8 +286,16 @@ class SpaceSeparatedSetOfChannels(registry.SpaceSeparatedListOf):
|
|||||||
channels_with_key.append(channel)
|
channels_with_key.append(channel)
|
||||||
else:
|
else:
|
||||||
channels.append(channel)
|
channels.append(channel)
|
||||||
if channels_with_key or channels:
|
msg = ircmsgs.joins(channels_with_key + channels, keys)
|
||||||
return ircmsgs.joins(channels_with_key + channels, keys)
|
if len(str(msg)) > 512:
|
||||||
|
msgs.append(old)
|
||||||
|
keys = []
|
||||||
|
channels_with_key = []
|
||||||
|
channels = []
|
||||||
|
old = msg
|
||||||
|
if msg:
|
||||||
|
msgs.append(msg)
|
||||||
|
return msgs
|
||||||
else:
|
else:
|
||||||
# Let's be explicit about it
|
# Let's be explicit about it
|
||||||
return None
|
return None
|
||||||
|
Loading…
Reference in New Issue
Block a user