diff --git a/src/lib/scraper/lookmovie.js b/src/lib/scraper/lookmovie.js index 7972cb79..fb596b45 100644 --- a/src/lib/scraper/lookmovie.js +++ b/src/lib/scraper/lookmovie.js @@ -91,12 +91,6 @@ async function getVideoUrl(config) { }; } -async function getEpisodeSubs (config) { - return await fetch(`${CORS_URL}/api/v1/shows/episode-subtitles/?id_episode=${config.id}`, { - headers: { phpsessid }, - }).then(res => res.json()); -} - async function getEpisodes(slug) { const url = `${CORS_URL}/shows/view/${slug}`; const pageReq = await fetch(url, { diff --git a/src/views/Movie.js b/src/views/Movie.js index f77ae4d4..c47522cb 100644 --- a/src/views/Movie.js +++ b/src/views/Movie.js @@ -57,9 +57,9 @@ export function MovieView(props) { setLoading(true); getStreamUrl(streamData.slug, streamData.type, streamData.source, season, episode) - .then(({ url }) => { + .then(({ url, subtitles }) => { if (cancel) return; - streamData.subtitles = []; + streamData.subtitles = subtitles; setStreamUrl(url) setLoading(false); })