mirror of
https://github.com/sussy-code/smov.git
synced 2025-01-04 16:47:40 +01:00
fix episode subtitles
This commit is contained in:
parent
150b8de8e8
commit
8ef38b151b
2 changed files with 2 additions and 8 deletions
|
@ -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) {
|
async function getEpisodes(slug) {
|
||||||
const url = `${CORS_URL}/shows/view/${slug}`;
|
const url = `${CORS_URL}/shows/view/${slug}`;
|
||||||
const pageReq = await fetch(url, {
|
const pageReq = await fetch(url, {
|
||||||
|
|
|
@ -57,9 +57,9 @@ export function MovieView(props) {
|
||||||
|
|
||||||
setLoading(true);
|
setLoading(true);
|
||||||
getStreamUrl(streamData.slug, streamData.type, streamData.source, season, episode)
|
getStreamUrl(streamData.slug, streamData.type, streamData.source, season, episode)
|
||||||
.then(({ url }) => {
|
.then(({ url, subtitles }) => {
|
||||||
if (cancel) return;
|
if (cancel) return;
|
||||||
streamData.subtitles = [];
|
streamData.subtitles = subtitles;
|
||||||
setStreamUrl(url)
|
setStreamUrl(url)
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue