From d20ab4be08ba25b1b5b23018faa5440a53edbeb1 Mon Sep 17 00:00:00 2001 From: Jorrin <43169049+JorrinKievit@users.noreply.github.com> Date: Tue, 27 Feb 2024 23:30:00 +0100 Subject: [PATCH] double map into one --- src/components/player/display/base.ts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/components/player/display/base.ts b/src/components/player/display/base.ts index 4d850923..a12661ab 100644 --- a/src/components/player/display/base.ts +++ b/src/components/player/display/base.ts @@ -152,10 +152,9 @@ export function makeVideoElementDisplayInterface(): DisplayInterface { if (isExtensionActiveCached()) { hls.on(Hls.Events.LEVEL_LOADED, async (_, data) => { - console.log(data); - const chunkUrlsDomains = data.details.fragments - .map((v) => v.url) - .map((v) => new URL(v).hostname); + const chunkUrlsDomains = data.details.fragments.map( + (v) => new URL(v.url).hostname, + ); const chunkUrls = [...new Set(chunkUrlsDomains)]; await setDomainRule({