mirror of https://github.com/Mikaela/Limnoria.git
update irc.reply() change new arg name
This commit is contained in:
parent
2fe84a3474
commit
bd2d17a1c2
|
@ -837,22 +837,23 @@ class NestedCommandsIrcProxy(ReplyIrcProxy):
|
||||||
cb._callCommand(command, self, self.msg, args)
|
cb._callCommand(command, self, self.msg, args)
|
||||||
|
|
||||||
def reply(self, s, noLengthCheck=False, prefixNick=None, action=None,
|
def reply(self, s, noLengthCheck=False, prefixNick=None, action=None,
|
||||||
private=None, notice=None, to=None, msg=None, usesendMsg=False):
|
private=None, notice=None, to=None, msg=None, sendImmediately=False):
|
||||||
"""
|
"""
|
||||||
Keyword arguments:
|
Keyword arguments:
|
||||||
|
|
||||||
* `noLengthCheck=False`: True if the length shouldn't be checked
|
* `noLengthCheck=False`: True if the length shouldn't be checked
|
||||||
(used for 'more' handling)
|
(used for 'more' handling)
|
||||||
* `prefixNick=True`: False if the nick shouldn't be prefixed to the
|
* `prefixNick=True`: False if the nick shouldn't be prefixed to the
|
||||||
reply.
|
reply.
|
||||||
* `action=False`: True if the reply should be an action.
|
* `action=False`: True if the reply should be an action.
|
||||||
* `private=False`: True if the reply should be in private.
|
* `private=False`: True if the reply should be in private.
|
||||||
* `notice=False`: True if the reply should be noticed when the
|
* `notice=False`: True if the reply should be noticed when the
|
||||||
bot is configured to do so.
|
bot is configured to do so.
|
||||||
* `to=<nick|channel>`: The nick or channel the reply should go to.
|
* `to=<nick|channel>`: The nick or channel the reply should go to.
|
||||||
Defaults to msg.args[0] (or msg.nick if private)
|
Defaults to msg.args[0] (or msg.nick if private)
|
||||||
* `usesendMsg=False`: True if the reply should be sent
|
* `sendImmediately=False`: True if the reply should use sendMsg() which
|
||||||
using sendMsg instead of queueMsg
|
bypasses conf.supybot.protocols.irc.throttleTime
|
||||||
|
and gets sent before any queued messages
|
||||||
"""
|
"""
|
||||||
# These use and or or based on whether or not they default to True or
|
# These use and or or based on whether or not they default to True or
|
||||||
# False. Those that default to True use and; those that default to
|
# False. Those that default to True use and; those that default to
|
||||||
|
@ -860,7 +861,7 @@ class NestedCommandsIrcProxy(ReplyIrcProxy):
|
||||||
assert not isinstance(s, ircmsgs.IrcMsg), \
|
assert not isinstance(s, ircmsgs.IrcMsg), \
|
||||||
'Old code alert: there is no longer a "msg" argument to reply.'
|
'Old code alert: there is no longer a "msg" argument to reply.'
|
||||||
self.repliedTo = True
|
self.repliedTo = True
|
||||||
if usesendMsg:
|
if sendImmediately:
|
||||||
sendMsg = self.irc.sendMsg
|
sendMsg = self.irc.sendMsg
|
||||||
else:
|
else:
|
||||||
sendMsg = self.irc.queueMsg
|
sendMsg = self.irc.queueMsg
|
||||||
|
|
Loading…
Reference in New Issue