mirror of
https://github.com/movie-web/providers.git
synced 2025-09-13 13:33:25 +00:00
Fix dood
This commit is contained in:
@@ -3,15 +3,20 @@ import { customAlphabet } from 'nanoid';
|
|||||||
import { makeEmbed } from '@/providers/base';
|
import { makeEmbed } from '@/providers/base';
|
||||||
|
|
||||||
const nanoid = customAlphabet('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789', 10);
|
const nanoid = customAlphabet('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789', 10);
|
||||||
|
const baseUrl = 'https://d000d.com';
|
||||||
|
|
||||||
export const doodScraper = makeEmbed({
|
export const doodScraper = makeEmbed({
|
||||||
id: 'dood',
|
id: 'dood',
|
||||||
name: 'dood',
|
name: 'dood',
|
||||||
rank: 173,
|
rank: 173,
|
||||||
async scrape(ctx) {
|
async scrape(ctx) {
|
||||||
const baseUrl = 'https://d0000d.com';
|
let url = ctx.url;
|
||||||
|
if (ctx.url.includes('primewire')) {
|
||||||
|
const request = await ctx.proxiedFetcher.full(ctx.url);
|
||||||
|
url = request.finalUrl;
|
||||||
|
}
|
||||||
|
|
||||||
const id = ctx.url.split('/d/')[1] || ctx.url.split('/e/')[1];
|
const id = url.split('/d/')[1] || url.split('/e/')[1];
|
||||||
|
|
||||||
const doodData = await ctx.proxiedFetcher<string>(`/e/${id}`, {
|
const doodData = await ctx.proxiedFetcher<string>(`/e/${id}`, {
|
||||||
method: 'GET',
|
method: 'GET',
|
||||||
|
@@ -51,6 +51,9 @@ async function getStreams(title: string) {
|
|||||||
case 'streamvid.net':
|
case 'streamvid.net':
|
||||||
embedId = 'streamvid';
|
embedId = 'streamvid';
|
||||||
break;
|
break;
|
||||||
|
case 'dood.watch':
|
||||||
|
embedId = 'dood';
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
embedId = null;
|
embedId = null;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user