From 126c126b955ba516b1b160f67274a7d2f0f44923 Mon Sep 17 00:00:00 2001 From: absidue <48293849+absidue@users.noreply.github.com> Date: Sat, 3 Aug 2024 14:40:32 +0200 Subject: [PATCH] Small cleanup after the YouTube.js update --- src/main/index.js | 6 ------ src/renderer/helpers/api/local.js | 4 ---- 2 files changed, 10 deletions(-) diff --git a/src/main/index.js b/src/main/index.js index 942cdb5827a1e..3d3cf427d5d01 100644 --- a/src/main/index.js +++ b/src/main/index.js @@ -994,12 +994,6 @@ function runApp() { try { const contents = await asyncFs.readFile(filePath) - // Probably a corrupted/broken cache entry, pretend it's absent - // A valid entry should be a few KB large - if (contents.byteLength < 500) { - return undefined - } - return contents.buffer } catch (e) { console.error(e) diff --git a/src/renderer/helpers/api/local.js b/src/renderer/helpers/api/local.js index e7fce2be2b5dc..fbdbab2894ac4 100644 --- a/src/renderer/helpers/api/local.js +++ b/src/renderer/helpers/api/local.js @@ -94,12 +94,8 @@ async function createInnertube({ withPlayer = false, location = undefined, safet const client = bodyJson.context.client client.clientVersion = clientVersion - client.deviceMake = 'Apple' client.deviceModel = 'iPhone16,2' // iPhone 15 Pro Max - client.osName = 'iOS' client.osVersion = iosVersion - delete client.browserName - delete client.browserVersion init.body = JSON.stringify(bodyJson) }