mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-24 03:29:28 +01:00
Irc.joinModes(): sort mode list before formatting
This commit is contained in:
parent
4cd49296e5
commit
cc40cacb7a
@ -749,6 +749,10 @@ class Irc():
|
|||||||
prefix = '+' # Assume we're adding modes unless told otherwise
|
prefix = '+' # Assume we're adding modes unless told otherwise
|
||||||
modelist = ''
|
modelist = ''
|
||||||
args = []
|
args = []
|
||||||
|
|
||||||
|
# Sort modes alphabetically like a conventional IRCd.
|
||||||
|
modes = sorted(modes)
|
||||||
|
|
||||||
for modepair in modes:
|
for modepair in modes:
|
||||||
mode, arg = modepair
|
mode, arg = modepair
|
||||||
assert len(mode) in (1, 2), "Incorrect length of a mode (received %r)" % mode
|
assert len(mode) in (1, 2), "Incorrect length of a mode (received %r)" % mode
|
||||||
|
Loading…
Reference in New Issue
Block a user