query channel MODEs on-JOIN

This commit is contained in:
jesopo 2020-04-02 22:57:22 +01:00
parent 63fa470a3f
commit 5b4714ca1e
1 changed files with 4 additions and 1 deletions

View File

@ -70,9 +70,12 @@ class Server(IServer):
await CAPContext(self).handshake()
async def _on_read_emit(self, line: Line, emit: Emit):
if emit.command == "CAP":
if emit.command == "CAP":
if emit.subcommand == "NEW":
await self._cap_new(emit)
elif emit.command == "JOIN":
if emit.self:
await self.send(build("MODE", [emit.channel.name]))
async def _on_read_line(self, line: Line):
for i, (response, future) in enumerate(self._wait_for):