move scraping functions to xvideos folder

This commit is contained in:
lamacchinadesiderante 2024-04-28 15:06:24 +02:00
parent 929b33f04c
commit ab9f048f87
5 changed files with 7 additions and 11 deletions

View File

@ -1,12 +1,8 @@
import axios from 'axios';
import * as cheerio from "cheerio";
import Layout from "@/components/Layout";
import Home from "@/components/Pages/Home";
import { fetchGalleryData } from '@/utils/scrape/gallery';
import { fetchGalleryData } from '@/utils/scrape/xvideos/gallery';
export default async function HomePage() {

View File

@ -2,7 +2,7 @@ import Layout from "@/components/Layout";
import Search from "@/components/Pages/Search";
import { fetchGalleryData } from "@/utils/scrape/gallery";
import { fetchGalleryData } from "@/utils/scrape/xvideos/gallery";
export default async function SearchPage({ params }: { params: { query: string } }) {

View File

@ -4,10 +4,10 @@ import Layout from "@/components/Layout";
import Video from "@/components/Pages/Video";
import { fetchVideoData } from "@/utils/scrape/video";
import { decodeVideoUrlPath } from '@/utils/string';
import { fetchVideoData } from '@/utils/scrape/xvideos/video';
import { useLocale } from 'next-intl';
export default async function VideoPage({ params }: { params: { id: string } }) {

View File

@ -3,7 +3,7 @@ import { GalleryData } from '@/meta/data';
import axios, { AxiosError } from 'axios';
import * as cheerio from "cheerio";
import { getHeaders } from './headers';
import { getHeaders } from '../headers';
interface FetchParams {
baseUrl?: string

View File

@ -4,8 +4,8 @@ import { GalleryData, VideoData } from '@/meta/data';
import axios, { AxiosError } from 'axios';
import * as cheerio from "cheerio";
import { findRelatedVideos, findVideoUrlInsideTagStringByFunctionNameAndExtension } from '../string';
import { getHeaders } from './headers';
import { findRelatedVideos, findVideoUrlInsideTagStringByFunctionNameAndExtension } from '../../string';
import { getHeaders } from '../headers';
interface FetchParams {
baseUrl?: string