diff --git a/package-lock.json b/package-lock.json index 4d066cd8..48337279 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "musix", - "version": "3.2.0", + "version": "3.2.2", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 61c64d59..e895340e 100644 --- a/package.json +++ b/package.json @@ -44,4 +44,4 @@ "ytdl-core": "^2.1.0", "zlib-sync": "^0.1.6" } -} \ No newline at end of file +} diff --git a/src/struct/funcs/play.js b/src/struct/funcs/play.js index 2740b42e..395f0410 100644 --- a/src/struct/funcs/play.js +++ b/src/struct/funcs/play.js @@ -16,7 +16,8 @@ module.exports = async function (guild, song, client, seek, play) { streamConfig.options.seek = seek; let input = song.url; - if (song.type === "ytdl") input = ytdl(song.url, streamConfig.ytdlOptions); + if (song.type === "ytdl") + input = ytdl(song.url, streamConfig.ytdlOptions); const ffmpegArgs = [ "-analyzeduration", @@ -44,10 +45,12 @@ module.exports = async function (guild, song, client, seek, play) { args.unshift("-ss", String(seek)); const transcoder = new prism.FFmpeg({ - args: args + args: args, }); - const stream = input.pipe(transcoder); + const stream = input.pipe(transcoder).on("error", (error) => { + console.log(error); + }); const dispatcher = queue.connection .play(stream, streamConfig.options)