Nick: fixing sitemap fallback

This commit is contained in:
Nicolas 2024-07-26 18:25:44 -04:00
parent 091924a636
commit 4c9d62f6d3
2 changed files with 2 additions and 1 deletions

View File

@ -139,4 +139,5 @@ export interface FireEngineOptions{
engine?: string;
blockMedia?: boolean;
blockAds?: boolean;
disableJsDom?: boolean;
}

View File

@ -23,7 +23,7 @@ export async function getLinksFromSitemap(
const response = await axios.get(sitemapUrl, { timeout: axiosTimeout });
content = response.data;
} else if (mode === 'fire-engine') {
const response = await scrapWithFireEngine({ url: sitemapUrl, fireEngineOptions: { method: "get", mobileProxy: true },options:{endpoint:"request"} });
const response = await scrapWithFireEngine({ url: sitemapUrl, fireEngineOptions: { engine:"tlsclient", disableJsDom: true, mobileProxy: true } });
content = response.html;
}
} catch (error) {