

@eventmgr_rfc1459.message('LIST')
def m_LIST(cli, ev_msg):
    cli.dump_numeric('321', ['Channel', 'Users', 'Topic'])
    for (ch_name, ch) in cli.ctx.channels.items():
        if ch.can_display(cli):
            cli.dump_numeric('322', [ch.name, str(len(ch.members)), ch.topic])
    cli.dump_numeric('323', ['End of /LIST'])

dataset/ETHPy150Open mammon-ircd/mammon/mammon/channel.py m_LIST/original