mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 13:19:24 +01:00
Fixed bug #857299.
This commit is contained in:
parent
b7fbaedcad
commit
f592aab3c0
@ -430,12 +430,16 @@ class IrcObjectProxy:
|
|||||||
if len(s) > allowedLength*50:
|
if len(s) > allowedLength*50:
|
||||||
log.warning('Cowardly refusing to "more" %s bytes.'%len(s))
|
log.warning('Cowardly refusing to "more" %s bytes.'%len(s))
|
||||||
s = s[:allowedLength*50]
|
s = s[:allowedLength*50]
|
||||||
|
if len(s) < allowedLength:
|
||||||
|
self.irc.queueMsg(reply(msg, s, self.prefixName,
|
||||||
|
self.private,self.notice,self.to))
|
||||||
|
return
|
||||||
msgs = textwrap.wrap(s, allowedLength-30) # -30 is for "nick:"
|
msgs = textwrap.wrap(s, allowedLength-30) # -30 is for "nick:"
|
||||||
msgs.reverse()
|
msgs.reverse()
|
||||||
response = msgs.pop()
|
response = msgs.pop()
|
||||||
if msgs:
|
if msgs:
|
||||||
response += ' \x02(%s)\x0F' % \
|
response = ircutils.bold('(%s)')
|
||||||
utils.nItems(len(msgs), 'message', 'more')
|
response %= utils.nItems(len(msgs), 'message', 'more')
|
||||||
mask = msg.prefix.split('!', 1)[1]
|
mask = msg.prefix.split('!', 1)[1]
|
||||||
Privmsg._mores[mask] = msgs
|
Privmsg._mores[mask] = msgs
|
||||||
private = self.private or not ircutils.isChannel(msg.args[0])
|
private = self.private or not ircutils.isChannel(msg.args[0])
|
||||||
|
Loading…
Reference in New Issue
Block a user