mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-03 23:36:43 +02:00
Fix Errors?
This commit is contained in:
+9
-1
@@ -97,4 +97,12 @@ client.on('guildDelete', async guild => {
|
||||
|
||||
client.login(TOKEN);
|
||||
|
||||
process.on('unhandledRejection', console.error);
|
||||
client.setTimeout(() => {
|
||||
console.log(`[RESTART] Shard ${client.shard.id} restarted!`);
|
||||
process.exit(0);
|
||||
}, 8.64e+7);
|
||||
|
||||
process.on('unhandledRejection', err => {
|
||||
console.error('Unhandled Promise Rejection:', err);
|
||||
process.exit(1);
|
||||
});
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "xiaobot",
|
||||
"version": "37.4.1",
|
||||
"version": "37.4.2",
|
||||
"description": "Your personal server companion.",
|
||||
"main": "Shard.js",
|
||||
"scripts": {
|
||||
|
||||
+2
-3
@@ -33,9 +33,8 @@ class Util {
|
||||
|
||||
static filterTopics(channels, setting) {
|
||||
return channels.filter(c => {
|
||||
if (c.type !== 'text' || !c.topic) return false;
|
||||
if (c.topic.includes(`<${setting}>`)) return true;
|
||||
return false;
|
||||
if (c.type !== 'text' || !c.topic || !c.permissionsFor(c.client.user).has('SEND_MESSAGES')) return false;
|
||||
return c.topic.includes(`<${setting}>`);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user