diff --git a/src/providers/DiscordMusicPlayer.ts b/src/providers/DiscordMusicPlayer.ts index 37c0db8..5f9eac4 100644 --- a/src/providers/DiscordMusicPlayer.ts +++ b/src/providers/DiscordMusicPlayer.ts @@ -683,6 +683,18 @@ class DiscordMusicPlayer { if (!videoId) throw new Error('YouTube link is invalid'); if (query.split('/')[4]) throw new Error('YouTube link is invalid'); + return { + videoId: videoId + }; + } else if ( + query.startsWith('https://www.youtube.com/shorts/') || + query.startsWith('http://www.youtube.com/shorts/') + ) { + let videoId = query.split('/')[4]; + + if (!videoId) throw new Error('YouTube link is invalid'); + if (query.split('/')[5]) throw new Error('YouTube link is invalid'); + return { videoId: videoId };