From da61f3e839082a34fc5ca7aa6235ff68adae2b4a Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Fri, 15 Jan 2021 20:16:14 -0500 Subject: [PATCH] Fix --- commands/games-sp/minesweeper.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commands/games-sp/minesweeper.js b/commands/games-sp/minesweeper.js index 321ef79c..cd6d149c 100644 --- a/commands/games-sp/minesweeper.js +++ b/commands/games-sp/minesweeper.js @@ -27,9 +27,9 @@ module.exports = class MinesweeperCommand extends Command { async run(msg, { size }) { const current = this.client.games.get(msg.channel.id); if (current) return msg.reply(`Please wait until the current game of \`${current.name}\` is finished.`); - this.client.games.set(msg.channel.id, { name: this.name }); try { const game = new BombSweeper(size, size); + this.client.games.set(msg.channel.id, { name: this.name, data: game }); game.PlaceBombs(size + 1); // eslint-disable-line new-cap let win = null; game.onWin = () => { win = true; };