'PART': _MsgParseExpectation(1, 2),
'PING': _MsgParseExpectation(1, source=''),
'PRIVMSG': _MsgParseExpectation(2),
+ 'QUIT': _MsgParseExpectation(1),
}
'users', msg.nick_from_source, stay_complete=True)
elif msg.match('PING'):
self.send(IrcMessage(verb='PONG', params=(msg.params[0],)))
+ elif msg.match('QUIT'):
+ user = msg.nick_from_source
+ for chan_name in self._db.chan_names:
+ chan = self._db.chan(chan_name)
+ if user in chan.users:
+ chan.remove_completable('users', user, stay_complete=True)
+ self._log(f'{user} quits: {msg.params[0]}',
+ scope=LogScope.CHAT, target=chan_name)
else:
self._log(f'PLEASE IMPLEMENT HANDLER FOR: {msg.raw}')