mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-06 06:10:49 +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(() => {
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "xiaobot",
|
||||
"version": "44.2.0",
|
||||
"version": "44.3.0",
|
||||
"description": "Your personal server companion.",
|
||||
"main": "Shard.js",
|
||||
"scripts": {
|
||||
|
||||
Reference in New Issue
Block a user