diff --git a/plugins/Admin/plugin.py b/plugins/Admin/plugin.py index f52430c0d..1b518635c 100644 --- a/plugins/Admin/plugin.py +++ b/plugins/Admin/plugin.py @@ -355,7 +355,7 @@ class Admin(callbacks.Plugin): Perform (with associated s on all channels on current network.""" for channel in irc.state.channels: - msg = ircmsgs.IrcMsg(msg=msg, args=(channel, *msg.args[1:])) + msg = ircmsgs.IrcMsg(msg=msg, args=(channel,) + msg.args[1:]) self.Proxy(irc.getRealIrc(), msg, commandAndArgs) acmd = wrap(acmd, ['admin', many('something')]) diff --git a/plugins/Admin/test.py b/plugins/Admin/test.py index 90b8ccc7e..f17b29972 100644 --- a/plugins/Admin/test.py +++ b/plugins/Admin/test.py @@ -132,7 +132,7 @@ class AdminTestCase(PluginTestCase): msgs.append(msg) msg = self.irc.takeMsg() self.assertCountEqual( - [(msg.command, *msg.args) for msg in msgs], + [(msg.command,) + msg.args for msg in msgs], [("PRIVMSG", "#foo", "hi #foo"), ("PRIVMSG", "#bar", "hi #bar")]) # vim:set shiftwidth=4 softtabstop=4 expandtab textwidth=79: diff --git a/plugins/User/plugin.py b/plugins/User/plugin.py index 2656dc5a0..579906c21 100644 --- a/plugins/User/plugin.py +++ b/plugins/User/plugin.py @@ -209,7 +209,14 @@ class User(callbacks.Plugin): password>. Obviously this message must be sent to the bot privately (not in a channel). If the requesting user is an owner user, then needn't be correct. + If the is "!", password login will be disabled. """ + if password == "!": + password = None + elif len(password) < 3: + irc.error(_('The password must be at least 3 characters long.'), + Raise=True) + try: u = ircdb.users.getUser(msg.prefix) except KeyError: diff --git a/src/irclib.py b/src/irclib.py index 0ceeff4e7..a74efda3c 100644 --- a/src/irclib.py +++ b/src/irclib.py @@ -1973,7 +1973,7 @@ class Irc(IrcCommandDispatcher, log.Firewalled): def do906(self, msg): log.warning('%s: SASL authentication aborted', self.network) - self.tryNextSaslMechanism(msg) + self.tryNextSaslMechanism(msg) # TODO: should not try this in state INIT_WAITING_MOTD (set when sending CAP END because of exhausted list of SASL mechs) def do907(self, msg): log.warning('%s: Attempted SASL authentication when we were already '