404 finally fixed
This commit is contained in:
parent
f30399c0d8
commit
74de1739c8
@ -44,7 +44,7 @@ export async function stream(url : string, error_check : boolean = false): Promi
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(error_check){
|
if(error_check){
|
||||||
let response = await got(info.video_details.url)
|
let response = await got(info.format[info.format.length - 1].url)
|
||||||
if(response.statusCode >= 400){
|
if(response.statusCode >= 400){
|
||||||
return await stream(info.video_details.url, true)
|
return await stream(info.video_details.url, true)
|
||||||
}
|
}
|
||||||
@ -78,7 +78,7 @@ export async function stream_from_info(info : InfoData, error_check : boolean =
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(error_check){
|
if(error_check){
|
||||||
let response = await got(info.video_details.url)
|
let response = await got(info.format[info.format.length - 1].url)
|
||||||
if(response.statusCode >= 400){
|
if(response.statusCode >= 400){
|
||||||
return await stream(info.video_details.url, true)
|
return await stream(info.video_details.url, true)
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user