mirror of
https://github.com/DarthKilroy/Spot.git
synced 2025-12-22 11:46:49 +00:00
de-OOPify stuff a little
This commit is contained in:
parent
c3fa0554c4
commit
2aadc1a1ef
6 changed files with 30 additions and 89 deletions
|
|
@ -9,18 +9,11 @@ const Guild = require('../model/guild');
|
|||
|
||||
const JAVASCRIPT_LOGO_URL = 'https://i.discord.fr/IEV8.png';
|
||||
|
||||
class Eval
|
||||
{
|
||||
constructor() {
|
||||
this.aliases = [];
|
||||
this.category = CommandCategory.BOT_MANAGEMENT;
|
||||
this.isAllowedForContext = CommandPermission.isMommy;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Message} message
|
||||
*/
|
||||
async process(message) {
|
||||
module.exports = {
|
||||
aliases: [],
|
||||
category: CommandCategory.BOT_MANAGEMENT,
|
||||
isAllowedForContext: CommandPermission.isMommy,
|
||||
process: async (message) => {
|
||||
const code = message.content
|
||||
.substr(Config.prefix.length + 'eval'.length)
|
||||
.trim()
|
||||
|
|
@ -44,6 +37,4 @@ class Eval
|
|||
|
||||
message.channel.send(embed).catch(error => Logger.warning(error.toString()));
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = new Eval();
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue