mirror of
https://git.nerdvpn.de/NerdVPN.de/invidious
synced 2026-02-14 22:51:42 +01:00
Remove obsolete video format patch
This commit is contained in:
@@ -1,33 +0,0 @@
|
||||
From 338fa57cf6ecad816a0b5143055f724788b814ec Mon Sep 17 00:00:00 2001
|
||||
From: weidenwiesel <webmaster@nerdvpn.de>
|
||||
Date: Mon, 13 Oct 2025 10:27:08 +0200
|
||||
Subject: [PATCH 4/4] [Patch] 004 - fix video format checks
|
||||
|
||||
---
|
||||
src/lib/jobs/potoken.ts | 5 ++---
|
||||
1 file changed, 2 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/src/lib/jobs/potoken.ts b/src/lib/jobs/potoken.ts
|
||||
index 5673c78..bbac16b 100644
|
||||
--- a/src/lib/jobs/potoken.ts
|
||||
+++ b/src/lib/jobs/potoken.ts
|
||||
@@ -191,14 +191,13 @@ async function checkToken({
|
||||
instantiatedInnertubeClient,
|
||||
youtubePlayerResponseJson,
|
||||
);
|
||||
- const validFormat = videoInfo.streaming_data
|
||||
- ?.adaptive_formats[0];
|
||||
+ const validFormat = videoInfo.streaming_data?.adaptive_formats[0].url || videoInfo.streaming_data?.formats[0].url;
|
||||
if (!validFormat) {
|
||||
throw new Error(
|
||||
"failed to find valid video with adaptive format to check token against",
|
||||
);
|
||||
}
|
||||
- const result = await fetchImpl(validFormat?.url, {
|
||||
+ const result = await fetchImpl(validFormat, {
|
||||
method: "HEAD",
|
||||
});
|
||||
if (result.status !== 200) {
|
||||
--
|
||||
2.39.5
|
||||
|
||||
Reference in New Issue
Block a user