diff --git a/src/modules/processing/services/soundcloud.js b/src/modules/processing/services/soundcloud.js index 04cdcc2b..389eaf6c 100644 --- a/src/modules/processing/services/soundcloud.js +++ b/src/modules/processing/services/soundcloud.js @@ -75,7 +75,7 @@ export default async function(obj) { let fileUrlBase = selectedStream.url; let fileUrl = `${fileUrlBase}${fileUrlBase.includes("?") ? "&" : "?"}client_id=${clientId}&track_authorization=${json.track_authorization}`; - if (fileUrl.substring(0, 54) !== "https://api-v2.soundcloud.com/media/soundcloud:tracks:") + if (!fileUrl.startsWith("https://api-v2.soundcloud.com/media/soundcloud:tracks:")) return { error: 'ErrorEmptyDownload' }; if (json.duration > env.durationLimit * 1000)