Release v1.6.23
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
9cceaacd14
commit
26b2ef0abb
+11
-1
@@ -62,7 +62,8 @@ function isRetryableErrorText(text: string): boolean {
|
||||
|| lower.includes("aborted")
|
||||
|| lower.includes("econnreset")
|
||||
|| lower.includes("enotfound")
|
||||
|| lower.includes("etimedout");
|
||||
|| lower.includes("etimedout")
|
||||
|| lower.includes("html statt json");
|
||||
}
|
||||
|
||||
function withTimeoutSignal(signal: AbortSignal | undefined, timeoutMs: number): AbortSignal {
|
||||
@@ -165,6 +166,15 @@ export class RealDebridClient {
|
||||
if (!directUrl) {
|
||||
throw new Error("Unrestrict ohne Download-URL");
|
||||
}
|
||||
try {
|
||||
const parsedUrl = new URL(directUrl);
|
||||
if (parsedUrl.protocol !== "https:" && parsedUrl.protocol !== "http:") {
|
||||
throw new Error(`Ungültiges Download-URL-Protokoll (${parsedUrl.protocol})`);
|
||||
}
|
||||
} catch (urlError) {
|
||||
if (urlError instanceof Error && urlError.message.includes("Protokoll")) throw urlError;
|
||||
throw new Error("Real-Debrid Antwort enthält keine gültige Download-URL");
|
||||
}
|
||||
|
||||
const fileName = String(payload.filename || "download.bin").trim() || "download.bin";
|
||||
const fileSizeRaw = Number(payload.filesize ?? NaN);
|
||||
|
||||
Reference in New Issue
Block a user