refactor: update text track types and clean up imports across multiple stream providers

This commit is contained in:
himanshu8443
2025-06-18 13:39:34 +05:30
parent e3208db7b0
commit dc009266be
10 changed files with 87 additions and 288 deletions

View File

@@ -1,4 +1,4 @@
import { Stream, ProviderContext, TextTracks, TextTrackType } from "../types";
import { Stream, ProviderContext, TextTracks } from "../types";
export const getStream = async function ({
link: id,
@@ -26,8 +26,8 @@ export const getStream = async function ({
uri: sub?.url,
title: sub?.lang || "Undefined",
type: sub?.url?.endsWith(".vtt")
? TextTrackType.VTT
: TextTrackType.SUBRIP,
? "text/vtt"
: "application/x-subrip",
});
});
res.data?.sources.forEach((source: any) => {