mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-02-17 06:00:42 +01:00
Added fix for servers with a missing MOTD file.
This commit is contained in:
parent
a714fce09d
commit
d013623e27
@ -187,7 +187,7 @@ if __name__ == '__main__':
|
|||||||
import callbacks
|
import callbacks
|
||||||
import OwnerCommands
|
import OwnerCommands
|
||||||
|
|
||||||
class ConfigAfter376(irclib.IrcCallback):
|
class ConfigAfterConnect(irclib.IrcCallback):
|
||||||
public = False
|
public = False
|
||||||
def __init__(self, commands):
|
def __init__(self, commands):
|
||||||
self.commands = commands
|
self.commands = commands
|
||||||
@ -196,6 +196,7 @@ if __name__ == '__main__':
|
|||||||
msg = ircmsgs.privmsg(irc.nick, command, prefix=irc.prefix)
|
msg = ircmsgs.privmsg(irc.nick, command, prefix=irc.prefix)
|
||||||
irc.queueMsg(msg)
|
irc.queueMsg(msg)
|
||||||
do377 = do376
|
do377 = do376
|
||||||
|
do422 = do376 # MOTD File is missing.
|
||||||
|
|
||||||
# We pre-tokenize the commands just to save on significant amounts of work.
|
# We pre-tokenize the commands just to save on significant amounts of work.
|
||||||
conf.commandsOnStart = map(callbacks.tokenize, conf.commandsOnStart)
|
conf.commandsOnStart = map(callbacks.tokenize, conf.commandsOnStart)
|
||||||
@ -204,7 +205,7 @@ if __name__ == '__main__':
|
|||||||
callback = OwnerCommands.Class()
|
callback = OwnerCommands.Class()
|
||||||
callback.configure(irc)
|
callback.configure(irc)
|
||||||
irc.addCallback(callback)
|
irc.addCallback(callback)
|
||||||
irc.addCallback(ConfigAfter376(afterConnect))
|
irc.addCallback(ConfigAfterConnect(afterConnect))
|
||||||
driver = drivers.newDriver(server, irc)
|
driver = drivers.newDriver(server, irc)
|
||||||
|
|
||||||
if options.profile:
|
if options.profile:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user