Skip to content
Snippets Groups Projects
Commit 145c460a authored by Reviath's avatar Reviath
Browse files

Added start_vote command.

parent 24a8e80b
Branches
Tags
No related merge requests found
const Discord = require("discord.js");
const errors = require('../errors.json');
exports.run = async (client, message, args) => {
const vote_message = args.join(' ');
if (!vote_message) {
message.channel.send(errors.insufficient_args).catch(e => {
return;
});
return;
};
const embed = new Discord.MessageEmbed()
.setTitle('Vote started!')
.setColor('RANDOM')
.setDescription(vote_message);
message.channel.send(embed).catch(e => {
message.channel.send(errors.cannot_send_embed).catch(e => {
return;
});
}).then(function(reactions) {
reactions.react('👍');
reactions.react('👎');
});
};
module.exports.help = {
name: 'start-vote',
aliases: ['start_vote']
};
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment