1
0
Fork 0
mirror of https://github.com/sussy-code/smov.git synced 2024-12-29 16:07:40 +01:00

🐛 FIX: Wrong title & more qualities to fallback

This commit is contained in:
cloud 2022-12-05 13:36:26 -07:00
parent c3df7795a7
commit 17d3da18b9

View file

@ -105,7 +105,7 @@ export const superStreamScraper: MWMediaProvider = {
media: MWPortableMedia,
): Promise<MWProviderMediaResult> {
let apiQuery: any;
if (media.mediaType === MWMediaType.MOVIE) {
if (media.mediaType === MWMediaType.SERIES) {
apiQuery = {
module: "TV_detail_1",
display_all: "1",
@ -175,7 +175,9 @@ export const superStreamScraper: MWMediaProvider = {
const mediaRes = (await get(apiQuery).then((r) => r.json())).data;
const hdQuality =
mediaRes.list.find((quality: any) => quality.quality === "1080p") ??
mediaRes.list.find((quality: any) => quality.quality === "720p");
mediaRes.list.find((quality: any) => quality.quality === "720p") ??
mediaRes.list.find((quality: any) => quality.quality === "480p") ??
mediaRes.list.find((quality: any) => quality.quality === "360p");
const subtitleApiQuery = {
fid: hdQuality.fid,