所以我有这个脚本,当创建频道时,它会在My_channels
上加上get_My_channels
上的on_channel_create
,但是我不知道如何从{ {1}},如果使用My_channels
删除了具有该名称的频道,那么当有消息发送到该频道时,它不会给我一个错误消息,那就是该频道不可用
on_channel_delete
#When channel is created it works
My_channels=[]
@client.event
async def on_channel_create(GlobalChat):
await get_My_channels() #< That line adds the created channel to My_channels if the channel has the name 'GlobalChat'