NickAuth: Detect extended-join based on capability.

It's more reliable than just checking the number of arguments
(eg. if a network decides to add its own set of arguments in
a way incompatible with extended-join).
This commit is contained in:
Valentin Lorentz 2020-06-12 19:11:15 +02:00
parent dd865583e7
commit 99cb656df0

View File

@ -188,8 +188,7 @@ class NickAuth(callbacks.Plugin):
self._auth(irc, msg.prefix, account)
def doJoin(self, irc, msg):
if len(msg.args) < 2:
# extended-join is not supported
if 'extended-join' not in irc.state.capabilities_ack:
return
account = msg.args[1]