mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-23 11:09:23 +01:00
Topic.reorder: Fixed some bugs found via jemfinch's new tests
This commit is contained in:
parent
88581d99e4
commit
05238bfcc6
@ -150,6 +150,9 @@ class Topic(callbacks.Privmsg, configurable.Mixin):
|
||||
except ValueError:
|
||||
irc.error(msg, 'The positions must be valid integers.')
|
||||
return
|
||||
if utils.sorted(order) != range(num):
|
||||
irc.error(msg, 'All topic numbers must be specified uniquely')
|
||||
return
|
||||
try:
|
||||
newtopics = [topics[i] for i in order]
|
||||
newtopic = self._joinTopic(newtopics, channel)
|
||||
|
Loading…
Reference in New Issue
Block a user