Update README.md
parent
35bbcb6c1e
commit
4b591f0a68
|
@ -9,7 +9,7 @@ A simple IRC client framework.
|
|||
## Parameters
|
||||
|
||||
~~~py
|
||||
irc = miniirc.IRC(ip, port, nick, channels = None, *, ssl = None, ident = None, realname = None, persist = False, debug = False, ns_identity = None, auto_connect = True)
|
||||
irc = miniirc.IRC(ip, port, nick, channels = None, *, ssl = None, ident = None, realname = None, persist = False, debug = False, ns_identity = None, auto_connect = True, ircv3_caps = set())
|
||||
~~~
|
||||
|
||||
| Parameter | Description |
|
||||
|
@ -25,6 +25,7 @@ irc = miniirc.IRC(ip, port, nick, channels = None, *, ssl = None, ident = None,
|
|||
| `debug` | Enables debug mode, prints all IRC messages. |
|
||||
| `ns_identity` | The NickServ account to use (`<user> <password>`). |
|
||||
| `auto_connect`| Runs `.connect()` straight away. |
|
||||
| `ircv3_caps` | A set() of IRCv3 capabilities to request. SASL is auto-added if `ns_identity` is specified. |
|
||||
|
||||
## Functions
|
||||
|
||||
|
|
|
@ -261,7 +261,7 @@ def _handler(irc, hostmask, args):
|
|||
# SASL
|
||||
@Handler('CAP')
|
||||
def _handler(irc, hostmask, args):
|
||||
if len(args) < 3 or not self.ns_identity:
|
||||
if len(args) < 3 or not irc.ns_identity:
|
||||
return
|
||||
elif args[1] == 'ACK' and args[2].replace(':', '', 1) == 'sasl':
|
||||
irc.quote('AUTHENTICATE PLAIN', force = True)
|
||||
|
|
Loading…
Reference in New Issue