From c3234b7cda6b452cb9f78311cbe3e184aadd87e3 Mon Sep 17 00:00:00 2001 From: 1computer1 Date: Wed, 22 May 2019 13:35:09 -0400 Subject: [PATCH] Add cleanup command --- src/commands/cleanup.js | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 src/commands/cleanup.js diff --git a/src/commands/cleanup.js b/src/commands/cleanup.js new file mode 100644 index 0000000..84e47d5 --- /dev/null +++ b/src/commands/cleanup.js @@ -0,0 +1,19 @@ +const { Command } = require('discord-akairo'); + +class CleanupCommand extends Command { + constructor() { + super('cleanup', { + aliases: ['cleanup'], + ownerOnly: true, + clientPermissions: ['SEND_MESSAGES'] + }); + } + + async exec(message) { + await message.util.send('Cleaning up...'); + await this.client.languageHandler.cleanup(); + await message.util.send('Cleaned up!'); + } +} + +module.exports = CleanupCommand;