From 755d7cde06e0563bb8df5db29678fc0ed373c1db Mon Sep 17 00:00:00 2001 From: Phxntxm Date: Sun, 23 Jul 2017 17:34:28 -0500 Subject: [PATCH] Use correct attribute for length of a song --- cogs/music.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/cogs/music.py b/cogs/music.py index 8f92905..e7371ef 100644 --- a/cogs/music.py +++ b/cogs/music.py @@ -68,8 +68,7 @@ class VoiceState: def skip(self): self.skip_votes.clear() - if self.playing: - self.voice.stop() + self.voice.stop() def after(self, _=None): if self.user_queue: @@ -683,7 +682,7 @@ class Music: if song.requester == author: found = True break - count += song.duration + count += song.length if not found: await ctx.send("You are not in the queue!") @@ -776,7 +775,7 @@ class Music: async def modskip(self, ctx): """Forces a song skip, can only be used by a moderator""" state = self.voice_states.get(ctx.message.guild.id) - if state is None or not state.playing: + if state is None: await ctx.send('Not playing any music right now...') return