mirror of
https://github.com/movie-web/providers.git
synced 2025-09-13 17:03:26 +00:00
add cors allowed flags
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { unpack } from 'unpacker';
|
||||
|
||||
import { SubtitleResult } from './types';
|
||||
import { flags } from '../../../../lib';
|
||||
import { makeEmbed } from '../../base';
|
||||
import { Caption, getCaptionTypeFromUrl, labelToLanguageCode } from '../../captions';
|
||||
|
||||
@@ -49,7 +50,7 @@ export const fileMoonScraper = makeEmbed({
|
||||
id: 'primary',
|
||||
type: 'hls',
|
||||
playlist: file[1],
|
||||
flags: [],
|
||||
flags: [flags.CORS_ALLOWED],
|
||||
captions,
|
||||
},
|
||||
],
|
||||
|
@@ -1,7 +1,8 @@
|
||||
import { flags } from '@/entrypoint/utils/targets';
|
||||
import { makeEmbed } from '@/providers/base';
|
||||
import { Caption, getCaptionTypeFromUrl, labelToLanguageCode } from '@/providers/captions';
|
||||
|
||||
import { getFileUrl, referer } from './common';
|
||||
import { getFileUrl } from './common';
|
||||
import { SubtitleResult, VidplaySourceResponse } from './types';
|
||||
|
||||
export const vidplayScraper = makeEmbed({
|
||||
@@ -44,12 +45,8 @@ export const vidplayScraper = makeEmbed({
|
||||
id: 'primary',
|
||||
type: 'hls',
|
||||
playlist: source,
|
||||
flags: [],
|
||||
flags: [flags.CORS_ALLOWED],
|
||||
captions,
|
||||
preferredHeaders: {
|
||||
Referer: referer,
|
||||
Origin: referer,
|
||||
},
|
||||
},
|
||||
],
|
||||
};
|
||||
|
@@ -1,5 +1,6 @@
|
||||
import { load } from 'cheerio';
|
||||
|
||||
import { flags } from '@/entrypoint/utils/targets';
|
||||
import { SourcererEmbed, SourcererOutput, makeSourcerer } from '@/providers/base';
|
||||
import { MovieScrapeContext, ShowScrapeContext } from '@/utils/context';
|
||||
|
||||
@@ -77,6 +78,6 @@ export const vidSrcToScraper = makeSourcerer({
|
||||
name: 'VidSrcTo',
|
||||
scrapeMovie: universalScraper,
|
||||
scrapeShow: universalScraper,
|
||||
flags: [],
|
||||
flags: [flags.CORS_ALLOWED],
|
||||
rank: 300,
|
||||
});
|
||||
|
Reference in New Issue
Block a user