|
|
@@ -466,10 +466,10 @@ class IRCClientProtocol(asyncio.Protocol): |
|
|
|
yield 'TOPIC', channel, f'Topic of {channel}: {line.params[2]}' |
|
|
|
elif line.command == ircstates.numerics.RPL_TOPICWHOTIME: |
|
|
|
yield 'TOPICWHO', line.params[1], f'Topic set by {irctokens.hostmask(line.params[2]).nickname} at {datetime.datetime.utcfromtimestamp(int(line.params[3])).replace(tzinfo = datetime.timezone.utc):%Y-%m-%d %H:%M:%SZ}' |
|
|
|
elif line.command == ircstates.numerics.RPL_NAMREPLY: |
|
|
|
channel = line.params[-2] |
|
|
|
nicks = [irctokens.hostmask(x).nickname for x in line.params[-1].split(' ')] |
|
|
|
yield 'NAMREPLY', channel, f'Currently in {channel}: {", ".join(nicks)}' |
|
|
|
elif line.command == ircstates.numerics.RPL_ENDOFNAMES: |
|
|
|
channel = line.params[1] |
|
|
|
users = self.server.channels[self.server.casefold(channel)].users |
|
|
|
yield 'NAMES', channel, f'Currently in {channel}: {", ".join(self.render_nick_with_mode(u, u.nickname) for u in users.values())}' |
|
|
|
|
|
|
|
async def quit(self): |
|
|
|
# The server acknowledges a QUIT by sending an ERROR and closing the connection. The latter triggers connection_lost, so just wait for the closure event. |
|
|
|