From 1cc6725fdd9e380f104c47959286e58a4dd86446 Mon Sep 17 00:00:00 2001 From: mudkipscience Date: Sat, 25 Jan 2020 21:45:12 +1100 Subject: [PATCH] FUCKING WORK MY GIOD --- config.js | 10 +++++----- src/events/message.js | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/config.js b/config.js index a1e45d2..28e46b1 100644 --- a/config.js +++ b/config.js @@ -3,11 +3,11 @@ const config = { "owners": ["433790467830972417", "324937993972350976"], // Tokens - "token": "", - "devtoken": "", - "ytkey": "", - "owmkey": "", - "dblkey": "", + "token": "NDM1OTYxNzA0MTQ1NDg1ODM1.XW762g.4uLWDkiz0tUkiAHZRrIW39ZJh6A", + "devtoken": "NDM5NTk0Njc1MjMwMjEyMDk2.XW77ww.izMA1miEMwRcM1-B6CM58qZq9d8", + "ytkey": "AIzaSyCCf9Q04Zy6tNOre3pTkiXRShI55kjGhmg", + "owmkey": "c49ea77cf0d3216a1cbc6b683f8d9117", + "dblkey": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjQzNTk2MTcwNDE0NTQ4NTgzNSIsImJvdCI6dHJ1ZSwiaWF0IjoxNTI5NDg5MzgzfQ.Wrjwn2ETwBfRZM7F3PiFf8Gy2MgBZ6Ry7vKv8WTxK_Y", // Default per-server settings "defaultSettings" : { diff --git a/src/events/message.js b/src/events/message.js index 6369b93..f63b531 100644 --- a/src/events/message.js +++ b/src/events/message.js @@ -16,6 +16,8 @@ module.exports = async (client, message) => { prefix = settings.devprefix; } + let blacklisted = false; + if(message.guild) { perms = message.channel.permissionsFor(client.user); @@ -24,7 +26,7 @@ module.exports = async (client, message) => { var adminRole = message.guild.roles.get(settings.adminRole); var autorole = message.guild.roles.get(settings.autorole); var mutedRole = message.guild.roles.get(settings.mutedRole); - var welcomeChannel = message.guild.channels.get(settings.welcomeChannel) + var welcomeChannel = message.guild.channels.get(settings.welcomeChannel); if(!welcomeChannel && settings.welcomeChannel != "off" || !adminRole && settings.adminRole != "None set" || !modRole && settings.modRole != "None set" || !mutedRole && settings.mutedRole != "None set" || !autorole && settings.autorole != "off") { @@ -121,8 +123,6 @@ module.exports = async (client, message) => { }; if(message.settings.blacklisted != "ARRAY" && settings.blacklisted.length > 0) { - let blacklisted = false; - settings.blacklisted.forEach(function(ID) { if(ID == message.author.id) { blacklisted = true;