From 285ee21919c1169f200f80cb74139dda8d30b30d Mon Sep 17 00:00:00 2001 From: drone1 Date: Mon, 7 Oct 2024 01:42:30 +0200 Subject: [PATCH] Replaces a string exception with an Error() exception --- lib/render.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/render.js b/lib/render.js index aa1df1b..36f5a5f 100644 --- a/lib/render.js +++ b/lib/render.js @@ -34,7 +34,7 @@ function getPcmData (filename, options, sampleCallback, endCallback) { } if (!fs.existsSync(filename)) { - throw `File doesn't exist: ${filename}` + throw new Error(`File doesn't exist: ${filename}`) } var ffmpeg = spawn('ffmpeg', ['-i', filename, '-f', 's16le', '-ac', channels,