mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-19 13:56:43 +02:00
<blocked> prevents commands
This commit is contained in:
@@ -77,6 +77,12 @@ client.on('guildDelete', async () => {
|
||||
postStats(count, client.user.id);
|
||||
});
|
||||
|
||||
client.dispatcher.addInhibitor(msg => {
|
||||
if (msg.channel.type !== 'text' || !msg.channel.topic) return false;
|
||||
if (msg.channel.topic.includes('<blocked>')) return 'topic blocked';
|
||||
return false;
|
||||
});
|
||||
|
||||
client.login(TOKEN);
|
||||
|
||||
client.setInterval(() => {
|
||||
|
||||
Reference in New Issue
Block a user