From 24cfe07310d2e6364a45581e6ac520cc4081dcc1 Mon Sep 17 00:00:00 2001 From: mudkipscience Date: Tue, 21 Apr 2020 17:01:28 +1000 Subject: [PATCH] fixed voteskip, added autoplay to guild schema --- commands/voteskip.js | 4 ++-- models/guild.js | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/commands/voteskip.js b/commands/voteskip.js index f82d8d3..489ecdb 100644 --- a/commands/voteskip.js +++ b/commands/voteskip.js @@ -27,9 +27,9 @@ exports.run = (client, message, args, level) => { ) } - const vc = message.guild.members.cache.get(client.user.id).voiceChannel + const vc = message.guild.members.cache.get(client.user.id).voice.channel - if (vc !== message.member.voiceChannel) { + if (vc !== message.member.voice.channel) { return message.channel.send( '<:error:466995152976871434> You need to be in my voice channel to use this command!' ) diff --git a/models/guild.js b/models/guild.js index 23ccbb8..1712da2 100644 --- a/models/guild.js +++ b/models/guild.js @@ -38,6 +38,11 @@ module.exports = model('Guild', new Schema({ } }, + autoplay: { + type: Boolean, + default: false + }, + plugins: { type: Object, default: {