From c5b103596a2f268b67a6add90621737e6dce81f9 Mon Sep 17 00:00:00 2001 From: Loic Bersier Date: Thu, 27 Sep 2018 15:22:36 +0200 Subject: [PATCH] Added feedback command --- commands/utility/feedback.js | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 commands/utility/feedback.js diff --git a/commands/utility/feedback.js b/commands/utility/feedback.js new file mode 100644 index 00000000..a030c17b --- /dev/null +++ b/commands/utility/feedback.js @@ -0,0 +1,25 @@ +const { Command } = require('discord.js-commando'); +const { feedbackChannel } = require('../../config.json'); +module.exports = class sayCommand extends Command { + constructor(client) { + super(client, { + name: 'feedback', + group: 'utility', + memberName: 'feedback', + description: `Send feedback`, + args: [ + { + key: 'text', + prompt: 'What do you want to send as a feedback?', + type: 'string', + } + ] + }); + } + + async run(message, { text }) { + const channel = this.client.channels.get(feedbackChannel); + channel.send(`from ${message.author}: ${text}`); + message.say('Your feedback have been sent!'); + } +}; \ No newline at end of file