mirror of
https://github.com/imputnet/cobalt.git
synced 2025-06-28 09:28:29 +00:00
排查不能下载视频的问题
This commit is contained in:
parent
aacf79f338
commit
1733ae76e2
@ -58,9 +58,10 @@
|
||||
if (final.includes(state)) {
|
||||
setTimeout(() => changeDownloadButton("idle"), 1500);
|
||||
}
|
||||
};
|
||||
}; export const download = async (link: string) => {
|
||||
// Log the link being processed
|
||||
console.log("[Cobalt BAM] Download button clicked for link:", link);
|
||||
|
||||
export const download = async (link: string) => {
|
||||
changeDownloadButton("think");
|
||||
|
||||
const response = await API.request(link);
|
||||
|
@ -35,6 +35,10 @@ const request = async (url: string) => {
|
||||
alwaysProxy: getSetting("privacy", "alwaysProxy"),
|
||||
}
|
||||
|
||||
// Log the URL being submitted to the backend
|
||||
console.log("[Cobalt BAM] Submitting URL to backend:", url);
|
||||
console.log("[Cobalt BAM] Full request object:", request);
|
||||
|
||||
/*await apiOverrideWarning();*/
|
||||
|
||||
await getServerInfo();
|
||||
@ -76,9 +80,7 @@ const request = async (url: string) => {
|
||||
"Authorization": `Bearer ${session.token}`,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
const response: Optional<CobaltAPIResponse> = await fetch(api, {
|
||||
} const response: Optional<CobaltAPIResponse> = await fetch(api, {
|
||||
method: "POST",
|
||||
redirect: "manual",
|
||||
signal: AbortSignal.timeout(10000),
|
||||
@ -101,6 +103,9 @@ const request = async (url: string) => {
|
||||
}
|
||||
});
|
||||
|
||||
// Log the API response
|
||||
console.log("[Cobalt BAM] API Response for URL", url, ":", response);
|
||||
|
||||
return response;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user