/** * ./commands/game/start.js */ const { Command } = require('discord.js-commando'); const { notAssigned } = require('../../guards.js'); module.exports = class StartCommand extends Command { constructor(client) { super(client, { name: 'start', memberName: 'start', group: 'game', description: `Starts new game round.`, guildOnly: true }); } async run(msg) { const { channel } = msg; // Guard that restricts the command to whitelisted channels const g = await notAssigned(msg, channel); if (g) return g; msg.react('🎉'); return msg.say(`**Round start!**`); } };