chore: removed unnecessary lines

This commit is contained in:
WBRK-dev
2024-04-28 11:47:44 +02:00
parent f6261199f8
commit 2f0157ab33
-4
View File
@@ -10,8 +10,6 @@ import axios, { AxiosError } from "axios";
import createHttpError, { type HttpError } from "http-errors"; import createHttpError, { type HttpError } from "http-errors";
import { load, type CheerioAPI, type SelectorType } from "cheerio"; import { load, type CheerioAPI, type SelectorType } from "cheerio";
import { type ScrapedAnimeAboutInfo } from "../types/parsers/index.js"; import { type ScrapedAnimeAboutInfo } from "../types/parsers/index.js";
import type { AnimePromotionalVideo } from "../types/anime.js";
import * as fs from "fs/promises";
// /anime/info?id=${anime-id} // /anime/info?id=${anime-id}
async function scrapeAnimeAboutInfo( async function scrapeAnimeAboutInfo(
@@ -59,8 +57,6 @@ async function scrapeAnimeAboutInfo(
const $: CheerioAPI = load(mainPage.data); const $: CheerioAPI = load(mainPage.data);
// fs.writeFile("./about.html", mainPage.data);
try { try {
res.anime.info.anilistId = Number( res.anime.info.anilistId = Number(
JSON.parse($("body")?.find("#syncData")?.text())?.anilist_id JSON.parse($("body")?.find("#syncData")?.text())?.anilist_id