diff --git a/bot/commands/Developer/eval.js b/bot/commands/Developer/eval.js index 0e9161c..1ff76ec 100644 --- a/bot/commands/Developer/eval.js +++ b/bot/commands/Developer/eval.js @@ -16,14 +16,14 @@ class Eval extends Command { const code = args.join(" "); try { const evaled = eval(code); - const clean = await this.client.util.clean(evaled); + const clean = await this.client.functions.clean(evaled); const MAX_CHARS = 3 + 2 + clean.length + 3; if (MAX_CHARS > 2000) { message.channel.send({ files: [new Discord.MessageAttachment(Buffer.from(clean), "output.txt")] }); } message.channel.send(`\`\`\`js\n${clean}\n\`\`\``); } catch (err) { - const e = await this.client.util.clean(err); + const e = await this.client.functions.clean(err); const MAX_CHARS = 1 + 5 + 1 + 3 + e.length + 3; console.log(MAX_CHARS); if (MAX_CHARS > 2000) { diff --git a/bot/events/message.js b/bot/events/message.js index 2d0a903..0e23b0b 100644 --- a/bot/events/message.js +++ b/bot/events/message.js @@ -23,7 +23,7 @@ module.exports = class { const cmd = this.client.commands.get(command) || this.client.commands.get(this.client.aliases.get(command)); if (!cmd) return; - if (cmd && cmd.conf.devOnly && this.client.util.isDeveloper(message.author.id) !== true) { + if (cmd && cmd.conf.devOnly && this.client.functions.isDeveloper(message.author.id) !== true) { return message.channel.send("devs only!"); } if (cmd && !message.guild && cmd.conf.guildOnly) { diff --git a/bot/index.js b/bot/index.js index 2786018..a401554 100644 --- a/bot/index.js +++ b/bot/index.js @@ -23,8 +23,7 @@ class Custom extends Client { this.path = __dirname; this.package = require("../package.json") this.logger = require("./util/logger"); - this.util = new (require("./util/util"))(this); - this.messageUtil = new (require("./util/messageUtil"))(this); + this.functions = new (require("./util/functions"))(this); this.db = new (require("./util/redis"))(this); // Create collections to store loaded commands and aliases in