mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-27 12:44:19 +01:00
Don't add line breaks in the middle of capability names.
This commit is contained in:
parent
fc06aa72a6
commit
307a2367f4
@ -1649,7 +1649,9 @@ class Irc(IrcCommandDispatcher, log.Firewalled):
|
|||||||
|
|
||||||
caps = ' '.join(sorted(caps))
|
caps = ' '.join(sorted(caps))
|
||||||
# textwrap works here because in ASCII, all chars are 1 bytes:
|
# textwrap works here because in ASCII, all chars are 1 bytes:
|
||||||
cap_lines = textwrap.wrap(caps, MAX_LINE_SIZE-len('CAP REQ :'))
|
cap_lines = textwrap.wrap(
|
||||||
|
caps, MAX_LINE_SIZE-len('CAP REQ :'),
|
||||||
|
break_long_words=False, break_on_hyphens=False)
|
||||||
for cap_line in cap_lines:
|
for cap_line in cap_lines:
|
||||||
self.sendMsg(ircmsgs.IrcMsg(command='CAP',
|
self.sendMsg(ircmsgs.IrcMsg(command='CAP',
|
||||||
args=('REQ', cap_line)))
|
args=('REQ', cap_line)))
|
||||||
|
Loading…
Reference in New Issue
Block a user