mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 13:19:24 +01:00
Fixed bugz0r in handling of nested actioning replies in tell.
This commit is contained in:
parent
096bbdc463
commit
ad4b7945ae
@ -438,6 +438,9 @@ class Misc(callbacks.Privmsg):
|
|||||||
if c.lobotomized:
|
if c.lobotomized:
|
||||||
irc.error('I\'m lobotomized in %s.' % target)
|
irc.error('I\'m lobotomized in %s.' % target)
|
||||||
return
|
return
|
||||||
|
if irc.action:
|
||||||
|
irc.action = False
|
||||||
|
text = '* %s %s' % (irc.nick, text)
|
||||||
s = '%s wants me to tell you: %s' % (msg.nick, text)
|
s = '%s wants me to tell you: %s' % (msg.nick, text)
|
||||||
irc.reply(s, to=target, private=True)
|
irc.reply(s, to=target, private=True)
|
||||||
|
|
||||||
@ -457,9 +460,9 @@ class Misc(callbacks.Privmsg):
|
|||||||
"""
|
"""
|
||||||
text = privmsgs.getArgs(args)
|
text = privmsgs.getArgs(args)
|
||||||
if text:
|
if text:
|
||||||
irc.queueMsg(ircmsgs.action(ircutils.replyTo(msg), ' '.join(args)))
|
irc.reply(text, action=True)
|
||||||
else:
|
else:
|
||||||
raise callbacks.Error
|
raise callbacks.ArgumentError
|
||||||
|
|
||||||
def notice(self, irc, msg, args):
|
def notice(self, irc, msg, args):
|
||||||
"""<text>
|
"""<text>
|
||||||
|
@ -138,6 +138,10 @@ class MiscTestCase(ChannelPluginTestCase, PluginDocumentation):
|
|||||||
m = self.getMsg('tell me you love me')
|
m = self.getMsg('tell me you love me')
|
||||||
self.failUnless(m.args[0] == self.nick)
|
self.failUnless(m.args[0] == self.nick)
|
||||||
|
|
||||||
|
def testTellDoesNotPropogateAction(self):
|
||||||
|
m = self.getMsg('tell foo [action bar]')
|
||||||
|
self.failIf(ircmsgs.isAction(m))
|
||||||
|
|
||||||
def testLast(self):
|
def testLast(self):
|
||||||
self.feedMsg('foo bar baz')
|
self.feedMsg('foo bar baz')
|
||||||
self.assertResponse('last', '<%s> foo bar baz' % self.nick)
|
self.assertResponse('last', '<%s> foo bar baz' % self.nick)
|
||||||
|
Loading…
Reference in New Issue
Block a user