From f09567b239eab6f775202b773ef261729b45d656 Mon Sep 17 00:00:00 2001 From: Emily J Date: Tue, 13 Apr 2021 17:25:16 +1000 Subject: [PATCH] THANK YOU FOR UNANNOUNCED API CHANGES --- src/commands/nowplaying.js | 2 +- src/commands/songinfo.js | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/commands/nowplaying.js b/src/commands/nowplaying.js index c26222d..69a5b22 100644 --- a/src/commands/nowplaying.js +++ b/src/commands/nowplaying.js @@ -17,7 +17,7 @@ exports.run = async (client, message) => { const embed = new MessageEmbed() embed.setTitle('Now playing') - embed.setThumbnail(s.video.videoThumbnails[1].url) + embed.setThumbnail('https://invidiou.site' + s.video.videoThumbnails[1].url) embed.setColor(client.embedColour(message)) embed.setDescription(`**[${s.video.title}](https://www.youtube.com/watch?v=${s.video.videoId})**`) embed.addField('Channel:', s.video.author, true) diff --git a/src/commands/songinfo.js b/src/commands/songinfo.js index cd7bb0b..6d3230c 100644 --- a/src/commands/songinfo.js +++ b/src/commands/songinfo.js @@ -15,8 +15,12 @@ exports.run = async (client, message, args) => { const s = guild.queue[songID] + if (!s) { + return message.channel.send('<:error:466995152976871434> No song was found in the position you specified.') + } + const embed = new MessageEmbed() - embed.setThumbnail(s.video.videoThumbnails[1].url) + embed.setThumbnail('https://invidiou.site' + s.video.videoThumbnails[1].url) embed.setColor(client.embedColour(message)) embed.setDescription(`**[${s.video.title}](https://www.youtube.com/watch?v=${s.video.videoId})**`) embed.addField('Channel:', s.video.author, true)